[{"data":1,"prerenderedAt":795},["ShallowReactive",2],{"navigation":3,"-guide-migration":234,"-guide-migration-surround":790},[4,81,228],{"title":5,"path":6,"stem":7,"children":8,"icon":10},"Getting Started","/guide","1.guide/0.index",[9,11,16,21,26,31,36,41,46,51,56,61,66,71,76],{"title":5,"path":6,"stem":7,"icon":10},"ph:book-open-duotone",{"title":12,"path":13,"stem":14,"icon":15},"Migration Guide","/guide/migration","1.guide/00.migration","ri:arrow-right-up-line",{"title":17,"path":18,"stem":19,"icon":20},"Server Utils","/guide/utils","1.guide/1.utils","ri:tools-line",{"title":22,"path":23,"stem":24,"icon":25},"Tasks","/guide/tasks","1.guide/10.tasks","codicon:run-all",{"title":27,"path":28,"stem":29,"icon":30},"Server Routes","/guide/routing","1.guide/2.routing","ri:direction-line",{"title":32,"path":33,"stem":34,"icon":35},"WebSocket","/guide/websocket","1.guide/3.websocket","cib:socket-io",{"title":37,"path":38,"stem":39,"icon":40},"KV Storage","/guide/storage","1.guide/4.storage","carbon:datastore",{"title":42,"path":43,"stem":44,"icon":45},"SQL Database","/guide/database","1.guide/5.database","ri:database-2-line",{"title":47,"path":48,"stem":49,"icon":50},"Cache","/guide/cache","1.guide/6.cache","ri:speed-line",{"title":52,"path":53,"stem":54,"icon":55},"Fetch","/guide/fetch","1.guide/7.fetch","ri:global-line",{"title":57,"path":58,"stem":59,"icon":60},"Assets","/guide/assets","1.guide/8.assets","ri:image-2-line",{"title":62,"path":63,"stem":64,"icon":65},"Plugins","/guide/plugins","1.guide/9.plugins","ri:plug-line",{"title":67,"path":68,"stem":69,"icon":70},"Configuration","/guide/configuration","1.guide/97.configuration","ri:settings-3-line",{"title":72,"path":73,"stem":74,"icon":75},"TypeScript","/guide/typescript","1.guide/98.typescript","tabler:brand-typescript",{"title":77,"path":78,"stem":79,"icon":80},"Nightly Channel","/guide/nightly","1.guide/99.nightly","ri:moon-fill",{"title":82,"path":83,"stem":84,"children":85,"icon":87},"Overview","/deploy","2.deploy/0.index",[86,88,92,122,127],{"title":82,"path":83,"stem":84,"icon":87},"ri:upload-cloud-2-line",{"title":89,"path":90,"stem":91,"icon":55},"Edge Workers","/deploy/workers","2.deploy/1.workers",{"title":93,"path":94,"stem":95,"children":96,"page":121},"Runtimes","/deploy/runtimes","2.deploy/10.runtimes",[97,102,106,111,116],{"title":98,"path":99,"stem":100,"icon":101},"Node.js","/deploy/runtimes/node","2.deploy/10.runtimes/1.node","akar-icons:node-fill",{"title":103,"path":104,"stem":105,"icon":25},"Dir","/deploy/runtimes/_dir","2.deploy/10.runtimes/_dir",{"title":107,"path":108,"stem":109,"icon":110},"WinterJS","/deploy/runtimes/_winterjs","2.deploy/10.runtimes/_winterjs","game-icons:cold-heart",{"title":112,"path":113,"stem":114,"icon":115},"Bun","/deploy/runtimes/bun","2.deploy/10.runtimes/bun","simple-icons:bun",{"title":117,"path":118,"stem":119,"icon":120},"Deno","/deploy/runtimes/deno","2.deploy/10.runtimes/deno","simple-icons:deno",false,{"title":123,"path":124,"stem":125,"icon":126},"Custom Preset","/deploy/custom-presets","2.deploy/2.custom-presets","ri:file-code-line",{"title":128,"path":129,"stem":130,"children":131,"page":121},"Providers","/deploy/providers","2.deploy/20.providers",[132,136,140,144,148,152,156,160,164,168,172,176,180,184,188,192,196,200,204,208,212,216,220,224],{"title":103,"path":133,"stem":134,"icon":135},"/deploy/providers/_dir","2.deploy/20.providers/_dir","tdesign:cloud",{"title":137,"path":138,"stem":139},"Alwaysdata","/deploy/providers/alwaysdata","2.deploy/20.providers/alwaysdata",{"title":141,"path":142,"stem":143},"AWS Lambda","/deploy/providers/aws","2.deploy/20.providers/aws",{"title":145,"path":146,"stem":147},"AWS Amplify","/deploy/providers/aws-amplify","2.deploy/20.providers/aws-amplify",{"title":149,"path":150,"stem":151},"Azure","/deploy/providers/azure","2.deploy/20.providers/azure",{"title":153,"path":154,"stem":155},"Cleavr","/deploy/providers/cleavr","2.deploy/20.providers/cleavr",{"title":157,"path":158,"stem":159},"Cloudflare","/deploy/providers/cloudflare","2.deploy/20.providers/cloudflare",{"title":161,"path":162,"stem":163},"Deno Deploy","/deploy/providers/deno-deploy","2.deploy/20.providers/deno-deploy",{"title":165,"path":166,"stem":167},"DigitalOcean","/deploy/providers/digitalocean","2.deploy/20.providers/digitalocean",{"title":169,"path":170,"stem":171},"Firebase","/deploy/providers/firebase","2.deploy/20.providers/firebase",{"title":173,"path":174,"stem":175},"Flightcontrol","/deploy/providers/flightcontrol","2.deploy/20.providers/flightcontrol",{"title":177,"path":178,"stem":179},"Genezio","/deploy/providers/genezio","2.deploy/20.providers/genezio",{"title":181,"path":182,"stem":183},"GitHub Pages","/deploy/providers/github-pages","2.deploy/20.providers/github-pages",{"title":185,"path":186,"stem":187},"GitLab Pages","/deploy/providers/gitlab-pages","2.deploy/20.providers/gitlab-pages",{"title":189,"path":190,"stem":191},"Heroku","/deploy/providers/heroku","2.deploy/20.providers/heroku",{"title":193,"path":194,"stem":195},"IIS","/deploy/providers/iis","2.deploy/20.providers/iis",{"title":197,"path":198,"stem":199},"Koyeb","/deploy/providers/koyeb","2.deploy/20.providers/koyeb",{"title":201,"path":202,"stem":203},"Netlify","/deploy/providers/netlify","2.deploy/20.providers/netlify",{"title":205,"path":206,"stem":207},"Platform.sh","/deploy/providers/platform-sh","2.deploy/20.providers/platform-sh",{"title":209,"path":210,"stem":211},"Render.com","/deploy/providers/render","2.deploy/20.providers/render",{"title":213,"path":214,"stem":215},"StormKit","/deploy/providers/stormkit","2.deploy/20.providers/stormkit",{"title":217,"path":218,"stem":219},"Vercel","/deploy/providers/vercel","2.deploy/20.providers/vercel",{"title":221,"path":222,"stem":223},"Zeabur","/deploy/providers/zeabur","2.deploy/20.providers/zeabur",{"title":225,"path":226,"stem":227},"Zerops","/deploy/providers/zerops","2.deploy/20.providers/zerops",{"title":229,"path":230,"stem":231,"children":232,"icon":70},"Config","/config","3.config/0.index",[233],{"title":229,"path":230,"stem":231,"icon":70},{"id":235,"title":12,"body":236,"description":304,"extension":785,"meta":786,"navigation":787,"path":13,"seo":788,"stem":14,"__hash__":789},"content/1.guide/00.migration.md",{"type":237,"value":238,"toc":775,"icon":15},"minimark",[239,246,249,261,276,293,298,345,350,365,369,379,382,387,402,406,414,423,427,444,448,454,459,474,478,488,491,495,502,506,509,512,700,704,707,742,748,752,771],[240,241,242],"note",{},[243,244,245],"p",{},"\nThis is a living document for migrating from Nitro 2 to 3. Please check it regularly while using the beta version.",[243,247,248],{},"Nitro v3 introduces intentional backward-incompatible changes. This guide helps you migrate from Nitro v2.",[250,251,253,257,258],"h2",{"id":252},"nitropack-is-renamed-to-nitro",[254,255,256],"code",{},"nitropack"," is renamed to ",[254,259,260],{},"nitro",[243,262,263,264,270,271,275],{},"The NPM package ",[265,266,256],"a",{"href":267,"rel":268},"https://www.npmjs.com/package/nitropack",[269],"nofollow"," (v2) has been renamed to ",[265,272,260],{"href":273,"rel":274},"https://www.npmjs.com/package/nitro",[269]," (v3).",[243,277,278,282,283,285,286,288,289,292],{},[279,280,281],"strong",{},"Migration:"," Update the ",[254,284,256],{}," dependency to ",[254,287,260],{}," in ",[254,290,291],{},"package.json",":",[240,294,295],{},[243,296,297],{},"\nCurrently, only nightly releases are available.",[299,300,305],"pre",{"className":301,"code":302,"language":303,"meta":304,"style":304},"language-diff shiki shiki-themes github-light github-dark github-dark","{\n  \"dependencies\": {\n--    \"nitropack\": \"latest\"\n++    \"nitro\": \"npm:nitro-nightly@latest\"\n  }\n}\n","diff","",[254,306,307,315,321,327,333,339],{"__ignoreMap":304},[308,309,312],"span",{"class":310,"line":311},"line",1,[308,313,314],{},"{\n",[308,316,318],{"class":310,"line":317},2,[308,319,320],{},"  \"dependencies\": {\n",[308,322,324],{"class":310,"line":323},3,[308,325,326],{},"--    \"nitropack\": \"latest\"\n",[308,328,330],{"class":310,"line":329},4,[308,331,332],{},"++    \"nitro\": \"npm:nitro-nightly@latest\"\n",[308,334,336],{"class":310,"line":335},5,[308,337,338],{},"  }\n",[308,340,342],{"class":310,"line":341},6,[308,343,344],{},"}\n",[243,346,347,349],{},[279,348,281],{}," Search your codebase and rename all instances of nitropack to nitro:",[299,351,353],{"className":301,"code":352,"language":303,"meta":304,"style":304},"-- import { defineNitroConfig } from \"nitropack/config\"\n++ import { defineNitroConfig } from \"nitro/config\"\n",[254,354,355,360],{"__ignoreMap":304},[308,356,357],{"class":310,"line":311},[308,358,359],{},"-- import { defineNitroConfig } from \"nitropack/config\"\n",[308,361,362],{"class":310,"line":317},[308,363,364],{},"++ import { defineNitroConfig } from \"nitro/config\"\n",[250,366,368],{"id":367},"nitroruntime","nitro/runtime/*",[243,370,371,372,375,376,378],{},"Previously, you could import from both ",[254,373,374],{},"nitro/runtime"," and ",[254,377,368],{},".",[243,380,381],{},"Support for nested paths has been removed to prevent exposing Nitro internals.",[243,383,384,386],{},[279,385,281],{}," Search for nitro/runtime/ imports and replace them with nitro/runtime:",[299,388,390],{"className":301,"code":389,"language":303,"meta":304,"style":304},"-- import { useStorage } from \"nitropack/runtime/storage\"\n++ import { useStorage } from \"nitro/runtime\"\n",[254,391,392,397],{"__ignoreMap":304},[308,393,394],{"class":310,"line":311},[308,395,396],{},"-- import { useStorage } from \"nitropack/runtime/storage\"\n",[308,398,399],{"class":310,"line":317},[308,400,401],{},"++ import { useStorage } from \"nitro/runtime\"\n",[250,403,405],{"id":404},"minimum-supported-nodejs-version-20","Minimum Supported Node.js Version: 20",[243,407,408,409,378],{},"Nitro now requires a minimum Node.js version of 20, as Node.js 18 reaches end-of-life in ",[265,410,413],{"href":411,"rel":412},"https://nodejs.org/en/about/previous-releases",[269],"April 2025",[243,415,416,417,422],{},"Please upgrade to the ",[265,418,421],{"href":419,"rel":420},"https://nodejs.org/en/download",[269],"latest LTS"," version (>= 20).",[243,424,425],{},[279,426,281],{},[428,429,430,438,441],"ul",{},[431,432,433,434,437],"li",{},"Check your local Node.js version using ",[254,435,436],{},"node --version"," and update if necessary.",[431,439,440],{},"If you use a CI/CD system for deployment, ensure that your pipeline is running Node.js 20 or higher.",[431,442,443],{},"If your hosting provider manages the Node.js runtime, make sure it’s set to version 20, 22, or later.",[250,445,447],{"id":446},"type-imports","Type Imports",[243,449,450,451,378],{},"Nitro types are now only exported from ",[254,452,453],{},"nitro/types",[243,455,456,458],{},[279,457,281],{}," Import types from nitro/types instead of nitro:",[299,460,462],{"className":301,"code":461,"language":303,"meta":304,"style":304},"-- import { NitroRuntimeConfig } from \"nitropack\"\n++ import { NitroRuntimeConfig } from \"nitro/types\"\n",[254,463,464,469],{"__ignoreMap":304},[308,465,466],{"class":310,"line":311},[308,467,468],{},"-- import { NitroRuntimeConfig } from \"nitropack\"\n",[308,470,471],{"class":310,"line":317},[308,472,473],{},"++ import { NitroRuntimeConfig } from \"nitro/types\"\n",[250,475,477],{"id":476},"app-config-support-removed","App Config Support Removed",[243,479,480,481,484,485,378],{},"Nitro v2 supported a bundled app config that allowed defining configurations in ",[254,482,483],{},"app.config.ts"," and accessing them at runtime via ",[254,486,487],{},"useAppConfig()",[243,489,490],{},"This feature had been removed.",[243,492,493],{},[279,494,281],{},[243,496,497,498,501],{},"Use a regular ",[254,499,500],{},".ts"," file in your server directory and import it directly.",[250,503,505],{"id":504},"preset-updates","Preset updates",[243,507,508],{},"Nitro presets have been updated for the latest compatibility.",[243,510,511],{},"Some (legacy) presets have been removed or renamed.",[513,514,515,528],"table",{},[516,517,518],"thead",{},[519,520,521,525],"tr",{},[522,523,524],"th",{},"Old Preset",[522,526,527],{},"New Preset",[529,530,531,549,568,581,597,610,625,637,649,661,671,681,691],"tbody",{},[519,532,533,539],{},[534,535,536],"td",{},[254,537,538],{},"node",[534,540,541,544,545,548],{},[254,542,543],{},"node-middleware"," (export changed to ",[254,546,547],{},"middleware",")",[519,550,551,563],{},[534,552,553,556,557,556,560],{},[254,554,555],{},"cloudflare",", ",[254,558,559],{},"cloudflare_worker",[254,561,562],{},"cloudflare_module_legacy",[534,564,565],{},[254,566,567],{},"cloudflare_module",[519,569,570,575],{},[534,571,572],{},[254,573,574],{},"deno-server-legacy",[534,576,577,580],{},[254,578,579],{},"deno_server"," with Deno v2",[519,582,583,588],{},[534,584,585],{},[254,586,587],{},"netlify-builder",[534,589,590,593,594],{},[254,591,592],{},"netlify_functions"," or ",[254,595,596],{},"netlify_edge",[519,598,599,604],{},[534,600,601],{},[254,602,603],{},"vercel-edge",[534,605,606,609],{},[254,607,608],{},"vercel"," with Fluid compute enabled",[519,611,612,620],{},[534,613,614,556,617],{},[254,615,616],{},"azure",[254,618,619],{},"azure_functions",[534,621,622],{},[254,623,624],{},"azure_swa",[519,626,627,632],{},[534,628,629],{},[254,630,631],{},"firebase",[534,633,634],{},[254,635,636],{},"firebase-functions",[519,638,639,644],{},[534,640,641],{},[254,642,643],{},"iis",[534,645,646],{},[254,647,648],{},"iis-handler",[519,650,651,656],{},[534,652,653],{},[254,654,655],{},"deno",[534,657,658],{},[254,659,660],{},"deno-deploy",[519,662,663,668],{},[534,664,665],{},[254,666,667],{},"edgio",[534,669,670],{},"Discontinued",[519,672,673,678],{},[534,674,675],{},[254,676,677],{},"cli",[534,679,680],{},"Removed due to lack of use",[519,682,683,688],{},[534,684,685],{},[254,686,687],{},"service_worker",[534,689,690],{},"Removed due to instability",[519,692,693,697],{},[534,694,695],{},[254,696,631],{},[534,698,699],{},"Use new firebase app hosting",[250,701,703],{"id":702},"removed-subpath-exports","Removed Subpath Exports",[243,705,706],{},"Nitro v2 introduced multiple subpath exports, some of which have been removed:",[428,708,709,717,722,727,732,737],{},[431,710,711,714,715,548],{},[254,712,713],{},"nitropack/core"," (use ",[254,716,260],{},[431,718,719],{},[254,720,721],{},"nitropack/runtime/*",[431,723,724],{},[254,725,726],{},"nitropack/dist/runtime/*",[431,728,729],{},[254,730,731],{},"nitropack/presets/*",[431,733,734],{},[254,735,736],{},"nitro/rollup",[431,738,739],{},[254,740,741],{},"nitropack/kit",[243,743,744,745,747],{},"An experimental ",[254,746,741],{}," was introduced but has now been removed. A standalone Nitro Kit package may be introduced in the future with clearer objectives.",[243,749,750],{},[279,751,281],{},[428,753,754,768],{},[431,755,756,757,760,761,763,764,767],{},"Use ",[254,758,759],{},"NitroModule"," from ",[254,762,453],{}," instead of ",[254,765,766],{},"defineNitroModule"," from the kit.",[431,769,770],{},"Prefer built-in Nitro presets (external presets are only for evaluation purposes).",[772,773,774],"style",{},"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);}",{"title":304,"searchDepth":317,"depth":317,"links":776},[777,779,780,781,782,783,784],{"id":252,"depth":317,"text":778},"nitropack is renamed to nitro",{"id":367,"depth":317,"text":368},{"id":404,"depth":317,"text":405},{"id":446,"depth":317,"text":447},{"id":476,"depth":317,"text":477},{"id":504,"depth":317,"text":505},{"id":702,"depth":317,"text":703},"md",{"icon":15},{"icon":15},{"title":12,"description":304},"NlreOqPH9_Yxjxng413lfvOrWG9CdhdOcL1STa_h0CM",[791,793],{"title":5,"path":6,"stem":7,"description":792,"icon":10,"children":-1},"Create web servers with all necessary features and deploy them wherever you prefer.",{"title":17,"path":18,"stem":19,"description":794,"icon":20,"children":-1},"Enjoy auto-imported server utils and extend with your own utils.",1778145697622]