[{"data":1,"prerenderedAt":810},["ShallowReactive",2],{"navigation":3,"-deploy-providers-azure":402,"-deploy-providers-azure-surround":805},[4,93,226,232,387,399],{"title":5,"path":6,"stem":7,"children":8,"icon":92},"","/docs","1.docs/1.index",[9,12,17,22,27,32,37,42,47,52,57,62,67,72,77,82,87],{"title":10,"path":6,"stem":7,"icon":11},"Introduction","i-lucide-compass",{"title":13,"path":14,"stem":15,"icon":16},"Quick Start","/docs/quick-start","1.docs/2.quick-start","i-lucide-zap",{"title":18,"path":19,"stem":20,"icon":21},"Renderer","/docs/renderer","1.docs/4.renderer","ri:layout-masonry-line",{"title":23,"path":24,"stem":25,"icon":26},"Routing","/docs/routing","1.docs/5.routing","ri:direction-line",{"title":28,"path":29,"stem":30,"icon":31},"Assets","/docs/assets","1.docs/50.assets","ri:image-2-line",{"title":33,"path":34,"stem":35,"icon":36},"Configuration","/docs/configuration","1.docs/50.configuration","ri:settings-3-line",{"title":38,"path":39,"stem":40,"icon":41},"Database","/docs/database","1.docs/50.database","ri:database-2-line",{"title":43,"path":44,"stem":45,"icon":46},"Lifecycle","/docs/lifecycle","1.docs/50.lifecycle","i-lucide-layers",{"title":48,"path":49,"stem":50,"icon":51},"OpenAPI","/docs/openapi","1.docs/50.openapi","ri:contract-line",{"title":53,"path":54,"stem":55,"icon":56},"Plugins","/docs/plugins","1.docs/50.plugins","ri:plug-line",{"title":58,"path":59,"stem":60,"icon":61},"Tasks","/docs/tasks","1.docs/50.tasks","codicon:run-all",{"title":63,"path":64,"stem":65,"icon":66},"WebSocket","/docs/websocket","1.docs/50.websocket","ri:broadcast-fill",{"title":68,"path":69,"stem":70,"icon":71},"Server Entry","/docs/server-entry","1.docs/6.server-entry","ri:server-line",{"title":73,"path":74,"stem":75,"icon":76},"Cache","/docs/cache","1.docs/7.cache","ri:speed-line",{"title":78,"path":79,"stem":80,"icon":81},"KV Storage","/docs/storage","1.docs/8.storage","carbon:datastore",{"title":83,"path":84,"stem":85,"icon":86},"Migration Guide","/docs/migration","1.docs/99.migration","ri:arrow-right-up-line",{"title":88,"path":89,"stem":90,"icon":91},"Nightly Channel","/docs/nightly","1.docs/99.nightly","ri:moon-fill","i-lucide-book-open",{"title":94,"path":95,"stem":96,"children":97,"icon":99},"Deploy","/deploy","2.deploy/0.index",[98,100,121],{"title":94,"path":95,"stem":96,"icon":99},"ri:upload-cloud-2-line",{"title":101,"path":102,"stem":103,"children":104,"page":120},"Runtimes","/deploy/runtimes","2.deploy/10.runtimes",[105,110,115],{"title":106,"path":107,"stem":108,"icon":109},"Node.js","/deploy/runtimes/node","2.deploy/10.runtimes/1.node","akar-icons:node-fill",{"title":111,"path":112,"stem":113,"icon":114},"Bun","/deploy/runtimes/bun","2.deploy/10.runtimes/bun","simple-icons:bun",{"title":116,"path":117,"stem":118,"icon":119},"Deno","/deploy/runtimes/deno","2.deploy/10.runtimes/deno","simple-icons:deno",false,{"title":122,"path":123,"stem":124,"children":125,"page":120},"Providers","/deploy/providers","2.deploy/20.providers",[126,130,134,138,142,146,150,154,158,162,166,170,174,178,182,186,190,194,198,202,206,210,214,218,222],{"title":127,"path":128,"stem":129},"Alwaysdata","/deploy/providers/alwaysdata","2.deploy/20.providers/alwaysdata",{"title":131,"path":132,"stem":133},"AWS Lambda","/deploy/providers/aws","2.deploy/20.providers/aws",{"title":135,"path":136,"stem":137},"AWS Amplify","/deploy/providers/aws-amplify","2.deploy/20.providers/aws-amplify",{"title":139,"path":140,"stem":141},"Azure","/deploy/providers/azure","2.deploy/20.providers/azure",{"title":143,"path":144,"stem":145},"Cleavr","/deploy/providers/cleavr","2.deploy/20.providers/cleavr",{"title":147,"path":148,"stem":149},"Cloudflare","/deploy/providers/cloudflare","2.deploy/20.providers/cloudflare",{"title":151,"path":152,"stem":153},"Deno Deploy","/deploy/providers/deno-deploy","2.deploy/20.providers/deno-deploy",{"title":155,"path":156,"stem":157},"DigitalOcean","/deploy/providers/digitalocean","2.deploy/20.providers/digitalocean",{"title":159,"path":160,"stem":161},"EdgeOne Pages","/deploy/providers/edgeone","2.deploy/20.providers/edgeone",{"title":163,"path":164,"stem":165},"Firebase","/deploy/providers/firebase","2.deploy/20.providers/firebase",{"title":167,"path":168,"stem":169},"Flightcontrol","/deploy/providers/flightcontrol","2.deploy/20.providers/flightcontrol",{"title":171,"path":172,"stem":173},"Genezio","/deploy/providers/genezio","2.deploy/20.providers/genezio",{"title":175,"path":176,"stem":177},"GitHub Pages","/deploy/providers/github-pages","2.deploy/20.providers/github-pages",{"title":179,"path":180,"stem":181},"GitLab Pages","/deploy/providers/gitlab-pages","2.deploy/20.providers/gitlab-pages",{"title":183,"path":184,"stem":185},"Heroku","/deploy/providers/heroku","2.deploy/20.providers/heroku",{"title":187,"path":188,"stem":189},"IIS","/deploy/providers/iis","2.deploy/20.providers/iis",{"title":191,"path":192,"stem":193},"Koyeb","/deploy/providers/koyeb","2.deploy/20.providers/koyeb",{"title":195,"path":196,"stem":197},"Netlify","/deploy/providers/netlify","2.deploy/20.providers/netlify",{"title":199,"path":200,"stem":201},"Platform.sh","/deploy/providers/platform-sh","2.deploy/20.providers/platform-sh",{"title":203,"path":204,"stem":205},"Render.com","/deploy/providers/render","2.deploy/20.providers/render",{"title":207,"path":208,"stem":209},"StormKit","/deploy/providers/stormkit","2.deploy/20.providers/stormkit",{"title":211,"path":212,"stem":213},"Vercel","/deploy/providers/vercel","2.deploy/20.providers/vercel",{"title":215,"path":216,"stem":217},"Zeabur","/deploy/providers/zeabur","2.deploy/20.providers/zeabur",{"title":219,"path":220,"stem":221},"Zephyr Cloud","/deploy/providers/zephyr","2.deploy/20.providers/zephyr",{"title":223,"path":224,"stem":225},"Zerops","/deploy/providers/zerops","2.deploy/20.providers/zerops",{"title":227,"path":228,"stem":229,"children":230,"icon":36},"Config","/config","3.config/0.index",[231],{"title":227,"path":228,"stem":229,"icon":36},{"title":233,"path":234,"stem":235,"children":236,"icon":238},"Examples","/examples","4.examples/0.index",[237,239,244,249,254,259,263,268,273,278,283,288,293,297,302,306,310,315,320,325,330,335,340,345,350,355,359,364,369,373,378,383],{"title":233,"path":234,"stem":235,"icon":238},"i-lucide-folder-code",{"title":240,"path":241,"stem":242,"icon":243},"API Routes","/examples/api-routes","4.examples/api-routes","i-lucide-route",{"title":245,"path":246,"stem":247,"icon":248},"Auto Imports","/examples/auto-imports","4.examples/auto-imports","i-lucide-import",{"title":250,"path":251,"stem":252,"icon":253},"Cached Handler","/examples/cached-handler","4.examples/cached-handler","i-lucide-clock",{"title":255,"path":256,"stem":257,"icon":258},"Custom Error Handler","/examples/custom-error-handler","4.examples/custom-error-handler","i-lucide-alert-circle",{"title":38,"path":260,"stem":261,"icon":262},"/examples/database","4.examples/database","i-lucide-database",{"title":264,"path":265,"stem":266,"icon":267},"Elysia","/examples/elysia","4.examples/elysia","i-skill-icons-elysia-dark",{"title":269,"path":270,"stem":271,"icon":272},"Express","/examples/express","4.examples/express","i-simple-icons-express",{"title":274,"path":275,"stem":276,"icon":277},"Fastify","/examples/fastify","4.examples/fastify","i-simple-icons-fastify",{"title":279,"path":280,"stem":281,"icon":282},"Hello World","/examples/hello-world","4.examples/hello-world","i-lucide-sparkles",{"title":284,"path":285,"stem":286,"icon":287},"Hono","/examples/hono","4.examples/hono","i-logos-hono",{"title":289,"path":290,"stem":291,"icon":292},"Import Alias","/examples/import-alias","4.examples/import-alias","i-lucide-at-sign",{"title":294,"path":295,"stem":296,"icon":46},"Middleware","/examples/middleware","4.examples/middleware",{"title":298,"path":299,"stem":300,"icon":301},"Mono JSX","/examples/mono-jsx","4.examples/mono-jsx","i-lucide-brackets",{"title":303,"path":304,"stem":305,"icon":301},"Nano JSX","/examples/nano-jsx","4.examples/nano-jsx",{"title":53,"path":307,"stem":308,"icon":309},"/examples/plugins","4.examples/plugins","i-lucide-plug",{"title":311,"path":312,"stem":313,"icon":314},"Custom Renderer","/examples/renderer","4.examples/renderer","i-lucide-code",{"title":316,"path":317,"stem":318,"icon":319},"Runtime Config","/examples/runtime-config","4.examples/runtime-config","i-lucide-settings",{"title":321,"path":322,"stem":323,"icon":324},"Server Fetch","/examples/server-fetch","4.examples/server-fetch","i-lucide-arrow-right-left",{"title":326,"path":327,"stem":328,"icon":329},"Shiki","/examples/shiki","4.examples/shiki","i-lucide-highlighter",{"title":331,"path":332,"stem":333,"icon":334},"Virtual Routes","/examples/virtual-routes","4.examples/virtual-routes","i-lucide-box",{"title":336,"path":337,"stem":338,"icon":339},"Vite Nitro Plugin","/examples/vite-nitro-plugin","4.examples/vite-nitro-plugin","i-logos-vitejs",{"title":341,"path":342,"stem":343,"icon":344},"Vite RSC","/examples/vite-rsc","4.examples/vite-rsc","i-logos-react",{"title":346,"path":347,"stem":348,"icon":349},"Vite SSR HTML","/examples/vite-ssr-html","4.examples/vite-ssr-html","i-logos-html-5",{"title":351,"path":352,"stem":353,"icon":354},"SSR with Preact","/examples/vite-ssr-preact","4.examples/vite-ssr-preact","i-logos-preact",{"title":356,"path":357,"stem":358,"icon":344},"SSR with React","/examples/vite-ssr-react","4.examples/vite-ssr-react",{"title":360,"path":361,"stem":362,"icon":363},"SSR with SolidJS","/examples/vite-ssr-solid","4.examples/vite-ssr-solid","i-logos-solidjs-icon",{"title":365,"path":366,"stem":367,"icon":368},"SSR with TanStack Router","/examples/vite-ssr-tsr-react","4.examples/vite-ssr-tsr-react","i-simple-icons-tanstack",{"title":370,"path":371,"stem":372,"icon":368},"SSR with TanStack Start","/examples/vite-ssr-tss-react","4.examples/vite-ssr-tss-react",{"title":374,"path":375,"stem":376,"icon":377},"SSR with Vue Router","/examples/vite-ssr-vue-router","4.examples/vite-ssr-vue-router","i-logos-vue",{"title":379,"path":380,"stem":381,"icon":382},"Vite + tRPC","/examples/vite-trpc","4.examples/vite-trpc","i-simple-icons-trpc",{"title":63,"path":384,"stem":385,"icon":386},"/examples/websocket","4.examples/websocket","i-lucide-radio",{"title":388,"path":389,"stem":390,"children":391},"Blog","/blog","9.blog",[392,395],{"title":388,"path":389,"stem":393,"icon":394},"9.blog/index","i-lucide-file-text",{"title":396,"path":397,"stem":398,"icon":394},"Nitro v3 Beta is here!","/blog/v3-beta","9.blog/1.v3-beta",{"title":5,"path":400,"stem":401},"/","index",{"id":403,"title":139,"body":404,"description":799,"extension":800,"meta":801,"navigation":802,"path":140,"seo":803,"stem":141,"__hash__":804},"content/2.deploy/20.providers/azure.md",{"type":405,"value":406,"toc":791},"minimark",[407,412,424,429,441,458,463,472,475,531,534,547,552,555,654,658,665,668,672,675,678,722,725,776,779,787],[408,409,411],"h2",{"id":410},"azure-static-web-apps","Azure static web apps",[413,414,415,419,420],"p",{},[416,417,418],"strong",{},"Preset:"," ",[421,422,423],"code",{},"azure-swa",[425,426],"read-more",{"title":427,"to":428},"Azure Static Web Apps","https://azure.microsoft.com/en-us/products/app-service/static",[430,431,432],"note",{},[413,433,434,435,440],{},"Integration with this provider is possible with ",[436,437,439],"a",{"href":438},"/deploy/#zero-config-providers","zero configuration",".",[413,442,443,447,448,453,454,457],{},[436,444,427],{"href":428,"rel":445},[446],"nofollow"," are designed to be deployed continuously in a ",[436,449,452],{"href":450,"rel":451},"https://docs.microsoft.com/en-us/azure/static-web-apps/github-actions-workflow",[446],"GitHub Actions workflow",". By default, Nitro will detect this deployment environment and enable the ",[421,455,456],{},"azure"," preset.",[459,460,462],"h3",{"id":461},"local-preview","Local preview",[413,464,465,466,471],{},"Install ",[436,467,470],{"href":468,"rel":469},"https://docs.microsoft.com/en-us/azure/azure-functions/functions-run-local",[446],"Azure Functions Core Tools"," if you want to test locally.",[413,473,474],{},"You can invoke a development environment to preview before deploying.",[476,477,481],"pre",{"className":478,"code":479,"language":480,"meta":5,"style":5},"language-bash shiki shiki-themes github-light github-dark github-dark","NITRO_PRESET=azure npx nypm@latest build\nnpx @azure/static-web-apps-cli start .output/public --api-location .output/server\n","bash",[421,482,483,509],{"__ignoreMap":5},[484,485,488,492,496,499,503,506],"span",{"class":486,"line":487},"line",1,[484,489,491],{"class":490},"slsVL","NITRO_PRESET",[484,493,495],{"class":494},"so5gQ","=",[484,497,456],{"class":498},"sfrk1",[484,500,502],{"class":501},"shcOC"," npx",[484,504,505],{"class":498}," nypm@latest",[484,507,508],{"class":498}," build\n",[484,510,512,515,518,521,524,528],{"class":486,"line":511},2,[484,513,514],{"class":501},"npx",[484,516,517],{"class":498}," @azure/static-web-apps-cli",[484,519,520],{"class":498}," start",[484,522,523],{"class":498}," .output/public",[484,525,527],{"class":526},"suiK_"," --api-location",[484,529,530],{"class":498}," .output/server\n",[459,532,33],{"id":533},"configuration",[413,535,536,537,542,543,546],{},"Azure Static Web Apps are ",[436,538,541],{"href":539,"rel":540},"https://learn.microsoft.com/en-us/azure/static-web-apps/configuration",[446],"configured"," using the ",[421,544,545],{},"staticwebapp.config.json"," file.",[413,548,549,550,457],{},"Nitro automatically generates this configuration file whenever the application is built with the ",[421,551,456],{},[413,553,554],{},"Nitro will automatically add the following properties based on the following criteria:",[556,557,558,574],"table",{},[559,560,561],"thead",{},[562,563,564,568,571],"tr",{},[565,566,567],"th",{},"Property",[565,569,570],{},"Criteria",[565,572,573],{},"Default",[575,576,577,604,625],"tbody",{},[562,578,579,589,600],{},[580,581,582],"td",{},[416,583,584],{},[436,585,588],{"href":586,"rel":587},"https://learn.microsoft.com/en-us/azure/static-web-apps/configuration#platform",[446],"platform.apiRuntime",[580,590,591,592,595,596,599],{},"Will automatically set to ",[421,593,594],{},"node:16"," or ",[421,597,598],{},"node:14"," depending on your package configuration.",[580,601,602],{},[421,603,594],{},[562,605,606,615,621],{},[580,607,608],{},[416,609,610],{},[436,611,614],{"href":612,"rel":613},"https://learn.microsoft.com/en-us/azure/static-web-apps/configuration#fallback-routes",[446],"navigationFallback.rewrite",[580,616,617,618],{},"Is always ",[421,619,620],{},"/api/server",[580,622,623],{},[421,624,620],{},[562,626,627,636,649],{},[580,628,629],{},[416,630,631],{},[436,632,635],{"href":633,"rel":634},"https://learn.microsoft.com/en-us/azure/static-web-apps/configuration#routes",[446],"routes",[580,637,638,639,642,643,646,647,440],{},"All prerendered routes are added. Additionally, if you do not have an ",[421,640,641],{},"index.html"," file an empty one is created for you for compatibility purposes and also requests to ",[421,644,645],{},"/index.html"," are redirected to the root directory which is handled by ",[421,648,620],{},[580,650,651],{},[421,652,653],{},"[]",[459,655,657],{"id":656},"custom-configuration","Custom configuration",[413,659,660,661,664],{},"You can alter the Nitro generated configuration using ",[421,662,663],{},"azure.config"," option.",[413,666,667],{},"Custom routes will be added and matched first. In the case of a conflict (determined if an object has the same route property), custom routes will override generated ones.",[459,669,671],{"id":670},"deploy-from-cicd-via-github-actions","Deploy from CI/CD via GitHub actions",[413,673,674],{},"When you link your GitHub repository to Azure Static Web Apps, a workflow file is added to the repository.",[413,676,677],{},"When you are asked to select your framework, select custom and provide the following information:",[556,679,680,690],{},[559,681,682],{},[562,683,684,687],{},[565,685,686],{},"Input",[565,688,689],{},"Value",[575,691,692,702,712],{},[562,693,694,699],{},[580,695,696],{},[416,697,698],{},"app_location",[580,700,701],{},"'/'",[562,703,704,709],{},[580,705,706],{},[416,707,708],{},"api_location",[580,710,711],{},"'.output/server'",[562,713,714,719],{},[580,715,716],{},[416,717,718],{},"output_location",[580,720,721],{},"'.output/public'",[413,723,724],{},"If you miss this step, you can always find the build configuration section in your workflow and update the build configuration:",[476,726,731],{"className":727,"code":728,"filename":729,"language":730,"meta":5,"style":5},"language-yaml shiki shiki-themes github-light github-dark github-dark","###### Repository/Build Configurations ######\napp_location: '/'\napi_location: '.output/server'\noutput_location: '.output/public'\n###### End of Repository/Build Configurations ######\n",".github/workflows/azure-static-web-apps-\u003CRANDOM_NAME>.yml","yaml",[421,732,733,739,750,760,770],{"__ignoreMap":5},[484,734,735],{"class":486,"line":487},[484,736,738],{"class":737},"sCsY4","###### Repository/Build Configurations ######\n",[484,740,741,744,747],{"class":486,"line":511},[484,742,698],{"class":743},"sByVh",[484,745,746],{"class":490},": ",[484,748,749],{"class":498},"'/'\n",[484,751,753,755,757],{"class":486,"line":752},3,[484,754,708],{"class":743},[484,756,746],{"class":490},[484,758,759],{"class":498},"'.output/server'\n",[484,761,763,765,767],{"class":486,"line":762},4,[484,764,718],{"class":743},[484,766,746],{"class":490},[484,768,769],{"class":498},"'.output/public'\n",[484,771,773],{"class":486,"line":772},5,[484,774,775],{"class":737},"###### End of Repository/Build Configurations ######\n",[413,777,778],{},"That's it! Now Azure Static Web Apps will automatically deploy your Nitro-powered application on push.",[413,780,781,782,440],{},"If you are using runtimeConfig, you will likely want to configure the corresponding ",[436,783,786],{"href":784,"rel":785},"https://docs.microsoft.com/en-us/azure/static-web-apps/application-settings",[446],"environment variables on Azure",[788,789,790],"style",{},"html pre.shiki code .slsVL, html code.shiki .slsVL{--shiki-light:#24292E;--shiki-default:#E1E4E8;--shiki-dark:#E1E4E8}html pre.shiki code .so5gQ, html code.shiki .so5gQ{--shiki-light:#D73A49;--shiki-default:#F97583;--shiki-dark:#F97583}html pre.shiki code .sfrk1, html code.shiki .sfrk1{--shiki-light:#032F62;--shiki-default:#9ECBFF;--shiki-dark:#9ECBFF}html pre.shiki code .shcOC, html code.shiki .shcOC{--shiki-light:#6F42C1;--shiki-default:#B392F0;--shiki-dark:#B392F0}html pre.shiki code .suiK_, html code.shiki .suiK_{--shiki-light:#005CC5;--shiki-default:#79B8FF;--shiki-dark:#79B8FF}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sCsY4, html code.shiki .sCsY4{--shiki-light:#6A737D;--shiki-default:#6A737D;--shiki-dark:#6A737D}html pre.shiki code .sByVh, html code.shiki .sByVh{--shiki-light:#22863A;--shiki-default:#85E89D;--shiki-dark:#85E89D}",{"title":5,"searchDepth":511,"depth":511,"links":792},[793],{"id":410,"depth":511,"text":411,"children":794},[795,796,797,798],{"id":461,"depth":752,"text":462},{"id":533,"depth":752,"text":33},{"id":656,"depth":752,"text":657},{"id":670,"depth":752,"text":671},"Deploy Nitro apps to Azure Static Web apps or functions.","md",{},{},{"title":139,"description":799},"_ziLV4_9x-aU8lxEd5iUyff7nvgZ1rMj9jc9mk35XMg",[806,808],{"title":135,"path":136,"stem":137,"description":807,"children":-1},"Deploy Nitro apps to AWS Amplify Hosting.",{"title":143,"path":144,"stem":145,"description":809,"children":-1},"Deploy Nitro apps to Cleavr.",1776367076971]