Skip to content

docs: Azure Static Web App deployment steps#7188

Open
Xiang-CH wants to merge 2 commits intoTanStack:mainfrom
Xiang-CH:patch-1
Open

docs: Azure Static Web App deployment steps#7188
Xiang-CH wants to merge 2 commits intoTanStack:mainfrom
Xiang-CH:patch-1

Conversation

@Xiang-CH
Copy link
Copy Markdown

@Xiang-CH Xiang-CH commented Apr 14, 2026

Added Azure Static Web App deployment instructions

Summary by CodeRabbit

  • Documentation
    • Added an Azure Static Web Apps hosting subsection for React: provider-specific deployment steps, configuration guidance, routing setup for server functions, explicit build/output path instructions, and guidance for apps located outside the project root.

Added Azure Static Web App deployment instructions
@github-actions github-actions bot added the documentation Everything documentation related label Apr 14, 2026
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 14, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: ff4d528b-2b3a-4ba4-82f4-155b877e53af

📥 Commits

Reviewing files that changed from the base of the PR and between 589bd4e and 3921b9c.

📒 Files selected for processing (1)
  • docs/start/framework/react/guide/hosting.md
✅ Files skipped from review due to trivial changes (1)
  • docs/start/framework/react/guide/hosting.md

📝 Walkthrough

Walkthrough

Added an "Azure Static Web App" hosting subsection to the React guide documenting copying a custom Nitro azure-swa-custom preset into the project root, updating vite.config.ts to use that preset and add a route rewrite for /_serverFn/*/api/server, and specifying Azure SWA build output locations.

Changes

Cohort / File(s) Summary
Azure SWA Deployment Guide
docs/start/framework/react/guide/hosting.md
Added Azure Static Web App instructions: copy azure-swa-custom Nitro preset to project root, configure vite.config.ts to use the preset and add a /_serverFn/*/api/server rewrite, and specify Azure SWA build output paths (including alternate app-location handling).

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐇 I hopped a presettled trail,
Copied Nitro, set the veil,
Rewrote routes from path to server,
Built the static, light and clever —
Azure skies, deployment sail.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title accurately describes the main change: adding Azure Static Web App deployment documentation to the hosting guide.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (2)
docs/start/framework/react/guide/hosting.md (2)

294-294: Avoid anchoring required deployment assets to a personal repository.

Line 294 points to a contributor-owned repo for a required preset directory. This can break docs if the repo moves or changes. Prefer a TanStack-owned location (this repo docs/examples) or inline the preset content.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/start/framework/react/guide/hosting.md` at line 294, The docs currently
link to a contributor-owned preset `azure-swa-custom` (the GitHub URL) for
required deployment assets; replace that external personal repo reference by
either copying the preset content directly into the docs/examples (inline the
entire preset in the repo) or hosting the preset in a TanStack-owned location
and updating the link to point to that canonical location, ensuring the guide
references `azure-swa-custom` from the project-owned source rather than the
contributor repo.

290-296: Fix wording/typos in the Azure SWA instructions.

There are multiple grammar/spelling issues that make the steps harder to follow (e.g., Line 290 “proporly”, Line 296 “Update you”, Line 324 “If you App”). Please clean these up.

Proposed text edits
-Azure SWA uses [`Nitro`](`#nitro`) for deployment, but the Nitro preset `azure-swa` needs to be extended for it to work proporly.
+Azure SWA uses [`Nitro`](`#nitro`) for deployment, but the Nitro preset `azure-swa` needs to be extended for it to work properly.

-1. Copy this custom nitro preset [`azure-swa-custom`](https://github.com/Xiang-CH/tanstack-azure-swa-template/tree/main/nitro) (the entire directory) in to your project root.
+1. Copy this custom Nitro preset [`azure-swa-custom`](https://github.com/Xiang-CH/tanstack-azure-swa-template/tree/main/nitro) (the entire directory) into your project root.

-2. Update you `vite.config.ts` with the following Nitro configuration:
+2. Update your `vite.config.ts` with the following Nitro configuration:

-4. If you App location is not the project root the build config should be the following:
+4. If your app location is not the project root, the build config should be the following:

Also applies to: 324-324

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs/start/framework/react/guide/hosting.md` around lines 290 - 296, Fix the
typos and improve wording in the Azure SWA instructions: change "proporly" to
"properly" in the sentence about the Nitro preset `azure-swa`, change "Update
you `vite.config.ts`" to "Update your `vite.config.ts`", and change "If you App"
to "If your App"; also smooth minor grammar (e.g., "Copy this custom nitro
preset" → "Copy the custom Nitro preset `azure-swa-custom` to your project
root") so the lines referencing the Nitro preset `azure-swa`, the custom preset
`azure-swa-custom`, and the `vite.config.ts` update read clearly and
consistently.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@docs/start/framework/react/guide/hosting.md`:
- Line 294: The docs currently link to a contributor-owned preset
`azure-swa-custom` (the GitHub URL) for required deployment assets; replace that
external personal repo reference by either copying the preset content directly
into the docs/examples (inline the entire preset in the repo) or hosting the
preset in a TanStack-owned location and updating the link to point to that
canonical location, ensuring the guide references `azure-swa-custom` from the
project-owned source rather than the contributor repo.
- Around line 290-296: Fix the typos and improve wording in the Azure SWA
instructions: change "proporly" to "properly" in the sentence about the Nitro
preset `azure-swa`, change "Update you `vite.config.ts`" to "Update your
`vite.config.ts`", and change "If you App" to "If your App"; also smooth minor
grammar (e.g., "Copy this custom nitro preset" → "Copy the custom Nitro preset
`azure-swa-custom` to your project root") so the lines referencing the Nitro
preset `azure-swa`, the custom preset `azure-swa-custom`, and the
`vite.config.ts` update read clearly and consistently.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 7007ee59-e690-47c4-849c-6b447fc658e2

📥 Commits

Reviewing files that changed from the base of the PR and between df61199 and 589bd4e.

📒 Files selected for processing (1)
  • docs/start/framework/react/guide/hosting.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Everything documentation related

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant