[{"data":1,"prerenderedAt":2037},["ShallowReactive",2],{"navigation":3,"-docs-tasks":394,"-docs-tasks-surround":2032},[4,88,217,223,379,391],{"title":5,"path":6,"stem":7,"children":8,"icon":87},"","/docs","1.docs/1.index",[9,12,17,22,27,32,37,42,47,52,57,62,67,72,77,82],{"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},"Server Entry","/docs/server-entry","1.docs/6.server-entry","ri:server-line",{"title":68,"path":69,"stem":70,"icon":71},"Cache","/docs/cache","1.docs/7.cache","ri:speed-line",{"title":73,"path":74,"stem":75,"icon":76},"KV Storage","/docs/storage","1.docs/8.storage","carbon:datastore",{"title":78,"path":79,"stem":80,"icon":81},"Migration Guide","/docs/migration","1.docs/99.migration","ri:arrow-right-up-line",{"title":83,"path":84,"stem":85,"icon":86},"Nightly Channel","/docs/nightly","1.docs/99.nightly","ri:moon-fill","i-lucide-book-open",{"title":89,"path":90,"stem":91,"children":92,"icon":94},"Deploy","/deploy","2.deploy/0.index",[93,95,116],{"title":89,"path":90,"stem":91,"icon":94},"ri:upload-cloud-2-line",{"title":96,"path":97,"stem":98,"children":99,"page":115},"Runtimes","/deploy/runtimes","2.deploy/10.runtimes",[100,105,110],{"title":101,"path":102,"stem":103,"icon":104},"Node.js","/deploy/runtimes/node","2.deploy/10.runtimes/1.node","akar-icons:node-fill",{"title":106,"path":107,"stem":108,"icon":109},"Bun","/deploy/runtimes/bun","2.deploy/10.runtimes/bun","simple-icons:bun",{"title":111,"path":112,"stem":113,"icon":114},"Deno","/deploy/runtimes/deno","2.deploy/10.runtimes/deno","simple-icons:deno",false,{"title":117,"path":118,"stem":119,"children":120,"page":115},"Providers","/deploy/providers","2.deploy/20.providers",[121,125,129,133,137,141,145,149,153,157,161,165,169,173,177,181,185,189,193,197,201,205,209,213],{"title":122,"path":123,"stem":124},"Alwaysdata","/deploy/providers/alwaysdata","2.deploy/20.providers/alwaysdata",{"title":126,"path":127,"stem":128},"AWS Lambda","/deploy/providers/aws","2.deploy/20.providers/aws",{"title":130,"path":131,"stem":132},"AWS Amplify","/deploy/providers/aws-amplify","2.deploy/20.providers/aws-amplify",{"title":134,"path":135,"stem":136},"Azure","/deploy/providers/azure","2.deploy/20.providers/azure",{"title":138,"path":139,"stem":140},"Cleavr","/deploy/providers/cleavr","2.deploy/20.providers/cleavr",{"title":142,"path":143,"stem":144},"Cloudflare","/deploy/providers/cloudflare","2.deploy/20.providers/cloudflare",{"title":146,"path":147,"stem":148},"Deno Deploy","/deploy/providers/deno-deploy","2.deploy/20.providers/deno-deploy",{"title":150,"path":151,"stem":152},"DigitalOcean","/deploy/providers/digitalocean","2.deploy/20.providers/digitalocean",{"title":154,"path":155,"stem":156},"Firebase","/deploy/providers/firebase","2.deploy/20.providers/firebase",{"title":158,"path":159,"stem":160},"Flightcontrol","/deploy/providers/flightcontrol","2.deploy/20.providers/flightcontrol",{"title":162,"path":163,"stem":164},"Genezio","/deploy/providers/genezio","2.deploy/20.providers/genezio",{"title":166,"path":167,"stem":168},"GitHub Pages","/deploy/providers/github-pages","2.deploy/20.providers/github-pages",{"title":170,"path":171,"stem":172},"GitLab Pages","/deploy/providers/gitlab-pages","2.deploy/20.providers/gitlab-pages",{"title":174,"path":175,"stem":176},"Heroku","/deploy/providers/heroku","2.deploy/20.providers/heroku",{"title":178,"path":179,"stem":180},"IIS","/deploy/providers/iis","2.deploy/20.providers/iis",{"title":182,"path":183,"stem":184},"Koyeb","/deploy/providers/koyeb","2.deploy/20.providers/koyeb",{"title":186,"path":187,"stem":188},"Netlify","/deploy/providers/netlify","2.deploy/20.providers/netlify",{"title":190,"path":191,"stem":192},"Platform.sh","/deploy/providers/platform-sh","2.deploy/20.providers/platform-sh",{"title":194,"path":195,"stem":196},"Render.com","/deploy/providers/render","2.deploy/20.providers/render",{"title":198,"path":199,"stem":200},"StormKit","/deploy/providers/stormkit","2.deploy/20.providers/stormkit",{"title":202,"path":203,"stem":204},"Vercel","/deploy/providers/vercel","2.deploy/20.providers/vercel",{"title":206,"path":207,"stem":208},"Zeabur","/deploy/providers/zeabur","2.deploy/20.providers/zeabur",{"title":210,"path":211,"stem":212},"Zephyr Cloud","/deploy/providers/zephyr","2.deploy/20.providers/zephyr",{"title":214,"path":215,"stem":216},"Zerops","/deploy/providers/zerops","2.deploy/20.providers/zerops",{"title":218,"path":219,"stem":220,"children":221,"icon":36},"Config","/config","3.config/0.index",[222],{"title":218,"path":219,"stem":220,"icon":36},{"title":224,"path":225,"stem":226,"children":227,"icon":229},"Examples","/examples","4.examples/0.index",[228,230,235,240,245,250,254,259,264,269,274,279,284,288,293,297,301,306,311,316,321,326,331,336,341,346,350,355,360,364,369,374],{"title":224,"path":225,"stem":226,"icon":229},"i-lucide-folder-code",{"title":231,"path":232,"stem":233,"icon":234},"API Routes","/examples/api-routes","4.examples/api-routes","i-lucide-route",{"title":236,"path":237,"stem":238,"icon":239},"Auto Imports","/examples/auto-imports","4.examples/auto-imports","i-lucide-import",{"title":241,"path":242,"stem":243,"icon":244},"Cached Handler","/examples/cached-handler","4.examples/cached-handler","i-lucide-clock",{"title":246,"path":247,"stem":248,"icon":249},"Custom Error Handler","/examples/custom-error-handler","4.examples/custom-error-handler","i-lucide-alert-circle",{"title":38,"path":251,"stem":252,"icon":253},"/examples/database","4.examples/database","i-lucide-database",{"title":255,"path":256,"stem":257,"icon":258},"Elysia","/examples/elysia","4.examples/elysia","i-skill-icons-elysia-dark",{"title":260,"path":261,"stem":262,"icon":263},"Express","/examples/express","4.examples/express","i-simple-icons-express",{"title":265,"path":266,"stem":267,"icon":268},"Fastify","/examples/fastify","4.examples/fastify","i-simple-icons-fastify",{"title":270,"path":271,"stem":272,"icon":273},"Hello World","/examples/hello-world","4.examples/hello-world","i-lucide-sparkles",{"title":275,"path":276,"stem":277,"icon":278},"Hono","/examples/hono","4.examples/hono","i-logos-hono",{"title":280,"path":281,"stem":282,"icon":283},"Import Alias","/examples/import-alias","4.examples/import-alias","i-lucide-at-sign",{"title":285,"path":286,"stem":287,"icon":46},"Middleware","/examples/middleware","4.examples/middleware",{"title":289,"path":290,"stem":291,"icon":292},"Mono JSX","/examples/mono-jsx","4.examples/mono-jsx","i-lucide-brackets",{"title":294,"path":295,"stem":296,"icon":292},"Nano JSX","/examples/nano-jsx","4.examples/nano-jsx",{"title":53,"path":298,"stem":299,"icon":300},"/examples/plugins","4.examples/plugins","i-lucide-plug",{"title":302,"path":303,"stem":304,"icon":305},"Custom Renderer","/examples/renderer","4.examples/renderer","i-lucide-code",{"title":307,"path":308,"stem":309,"icon":310},"Runtime Config","/examples/runtime-config","4.examples/runtime-config","i-lucide-settings",{"title":312,"path":313,"stem":314,"icon":315},"Server Fetch","/examples/server-fetch","4.examples/server-fetch","i-lucide-arrow-right-left",{"title":317,"path":318,"stem":319,"icon":320},"Shiki","/examples/shiki","4.examples/shiki","i-lucide-highlighter",{"title":322,"path":323,"stem":324,"icon":325},"Virtual Routes","/examples/virtual-routes","4.examples/virtual-routes","i-lucide-box",{"title":327,"path":328,"stem":329,"icon":330},"Vite Nitro Plugin","/examples/vite-nitro-plugin","4.examples/vite-nitro-plugin","i-logos-vitejs",{"title":332,"path":333,"stem":334,"icon":335},"Vite RSC","/examples/vite-rsc","4.examples/vite-rsc","i-logos-react",{"title":337,"path":338,"stem":339,"icon":340},"Vite SSR HTML","/examples/vite-ssr-html","4.examples/vite-ssr-html","i-logos-html-5",{"title":342,"path":343,"stem":344,"icon":345},"SSR with Preact","/examples/vite-ssr-preact","4.examples/vite-ssr-preact","i-logos-preact",{"title":347,"path":348,"stem":349,"icon":335},"SSR with React","/examples/vite-ssr-react","4.examples/vite-ssr-react",{"title":351,"path":352,"stem":353,"icon":354},"SSR with SolidJS","/examples/vite-ssr-solid","4.examples/vite-ssr-solid","i-logos-solidjs-icon",{"title":356,"path":357,"stem":358,"icon":359},"SSR with TanStack Router","/examples/vite-ssr-tsr-react","4.examples/vite-ssr-tsr-react","i-simple-icons-tanstack",{"title":361,"path":362,"stem":363,"icon":359},"SSR with TanStack Start","/examples/vite-ssr-tss-react","4.examples/vite-ssr-tss-react",{"title":365,"path":366,"stem":367,"icon":368},"SSR with Vue Router","/examples/vite-ssr-vue-router","4.examples/vite-ssr-vue-router","i-logos-vue",{"title":370,"path":371,"stem":372,"icon":373},"Vite + tRPC","/examples/vite-trpc","4.examples/vite-trpc","i-simple-icons-trpc",{"title":375,"path":376,"stem":377,"icon":378},"WebSocket","/examples/websocket","4.examples/websocket","i-lucide-radio",{"title":380,"path":381,"stem":382,"children":383},"Blog","/blog","9.blog",[384,387],{"title":380,"path":381,"stem":385,"icon":386},"9.blog/index","i-lucide-file-text",{"title":388,"path":389,"stem":390,"icon":386},"Nitro v3 Beta is here!","/blog/v3-beta","9.blog/1.v3-beta",{"title":5,"path":392,"stem":393},"/","index",{"id":395,"title":58,"body":396,"description":2026,"extension":2027,"meta":2028,"navigation":2029,"path":59,"seo":2030,"stem":60,"__hash__":2031},"content/1.docs/50.tasks.md",{"type":397,"value":398,"toc":2004,"icon":61},"minimark",[399,404,419,422,506,510,517,532,538,649,654,661,700,810,815,823,858,911,915,918,1010,1021,1025,1028,1108,1114,1126,1140,1144,1229,1234,1237,1249,1331,1335,1346,1350,1467,1471,1477,1491,1497,1501,1504,1508,1515,1518,1647,1653,1659,1906,1912,1916,1925,1929,1947,1951,1974,1980,1984,1988,1995,2000],[400,401,403],"h2",{"id":402},"opt-in-to-the-experimental-feature","Opt-in to the experimental feature",[405,406,407],"important",{},[408,409,410,411,418],"p",{},"\nTasks support is currently experimental.\nSee ",[412,413,417],"a",{"href":414,"rel":415},"https://github.com/nitrojs/nitro/issues/1974",[416],"nofollow","nitrojs/nitro#1974"," for the relevant discussion.",[408,420,421],{},"In order to use the tasks API you need to enable experimental feature flag.",[423,424,429],"pre",{"className":425,"code":426,"filename":427,"language":428,"meta":5,"style":5},"language-ts shiki shiki-themes github-light github-dark github-dark","import { defineNitroConfig } from \"nitro/config\";\n\nexport default defineNitroConfig({\n  experimental: {\n    tasks: true\n  }\n})\n","nitro.config.ts","ts",[430,431,432,455,462,478,484,494,500],"code",{"__ignoreMap":5},[433,434,437,441,445,448,452],"span",{"class":435,"line":436},"line",1,[433,438,440],{"class":439},"so5gQ","import",[433,442,444],{"class":443},"slsVL"," { defineNitroConfig } ",[433,446,447],{"class":439},"from",[433,449,451],{"class":450},"sfrk1"," \"nitro/config\"",[433,453,454],{"class":443},";\n",[433,456,458],{"class":435,"line":457},2,[433,459,461],{"emptyLinePlaceholder":460},true,"\n",[433,463,465,468,471,475],{"class":435,"line":464},3,[433,466,467],{"class":439},"export",[433,469,470],{"class":439}," default",[433,472,474],{"class":473},"shcOC"," defineNitroConfig",[433,476,477],{"class":443},"({\n",[433,479,481],{"class":435,"line":480},4,[433,482,483],{"class":443},"  experimental: {\n",[433,485,487,490],{"class":435,"line":486},5,[433,488,489],{"class":443},"    tasks: ",[433,491,493],{"class":492},"suiK_","true\n",[433,495,497],{"class":435,"line":496},6,[433,498,499],{"class":443},"  }\n",[433,501,503],{"class":435,"line":502},7,[433,504,505],{"class":443},"})\n",[400,507,509],{"id":508},"define-tasks","Define tasks",[408,511,512,513,516],{},"Tasks can be defined in ",[430,514,515],{},"tasks/[name].ts"," files.",[408,518,519,520,523,524,527,528,531],{},"Nested directories are supported. The task name will be joined with ",[430,521,522],{},":",". (Example: ",[430,525,526],{},"tasks/db/migrate.ts"," task name will be ",[430,529,530],{},"db:migrate",")",[408,533,534],{},[535,536,537],"strong",{},"Example:",[423,539,541],{"className":425,"code":540,"filename":526,"language":428,"meta":5,"style":5},"export default defineTask({\n  meta: {\n    name: \"db:migrate\",\n    description: \"Run database migrations\",\n  },\n  run({ payload, context }) {\n    console.log(\"Running DB migration task...\");\n    return { result: \"Success\" };\n  },\n});\n",[430,542,543,554,559,570,580,585,606,623,638,643],{"__ignoreMap":5},[433,544,545,547,549,552],{"class":435,"line":436},[433,546,467],{"class":439},[433,548,470],{"class":439},[433,550,551],{"class":473}," defineTask",[433,553,477],{"class":443},[433,555,556],{"class":435,"line":457},[433,557,558],{"class":443},"  meta: {\n",[433,560,561,564,567],{"class":435,"line":464},[433,562,563],{"class":443},"    name: ",[433,565,566],{"class":450},"\"db:migrate\"",[433,568,569],{"class":443},",\n",[433,571,572,575,578],{"class":435,"line":480},[433,573,574],{"class":443},"    description: ",[433,576,577],{"class":450},"\"Run database migrations\"",[433,579,569],{"class":443},[433,581,582],{"class":435,"line":486},[433,583,584],{"class":443},"  },\n",[433,586,587,590,593,597,600,603],{"class":435,"line":496},[433,588,589],{"class":473},"  run",[433,591,592],{"class":443},"({ ",[433,594,596],{"class":595},"sQHwn","payload",[433,598,599],{"class":443},", ",[433,601,602],{"class":595},"context",[433,604,605],{"class":443}," }) {\n",[433,607,608,611,614,617,620],{"class":435,"line":502},[433,609,610],{"class":443},"    console.",[433,612,613],{"class":473},"log",[433,615,616],{"class":443},"(",[433,618,619],{"class":450},"\"Running DB migration task...\"",[433,621,622],{"class":443},");\n",[433,624,626,629,632,635],{"class":435,"line":625},8,[433,627,628],{"class":439},"    return",[433,630,631],{"class":443}," { result: ",[433,633,634],{"class":450},"\"Success\"",[433,636,637],{"class":443}," };\n",[433,639,641],{"class":435,"line":640},9,[433,642,584],{"class":443},[433,644,646],{"class":435,"line":645},10,[433,647,648],{"class":443},"});\n",[650,651,653],"h3",{"id":652},"task-interface","Task interface",[408,655,656,657,660],{},"The ",[430,658,659],{},"defineTask"," helper accepts an object with the following properties:",[662,663,664,681],"ul",{},[665,666,667,672,673,676,677,680],"li",{},[535,668,669],{},[430,670,671],{},"meta"," (optional): An object with optional ",[430,674,675],{},"name"," and ",[430,678,679],{},"description"," string fields used for display in the dev server and CLI.",[665,682,683,688,689,695,696,699],{},[535,684,685],{},[430,686,687],{},"run"," (required): A function that receives a ",[412,690,692],{"href":691},"#taskevent",[430,693,694],{},"TaskEvent"," and returns (or resolves to) an object with an optional ",[430,697,698],{},"result"," property.",[423,701,703],{"className":425,"code":702,"language":428,"meta":5,"style":5},"interface Task\u003CRT = unknown> {\n  meta?: { name?: string; description?: string };\n  run(event: TaskEvent): { result?: RT } | Promise\u003C{ result?: RT }>;\n}\n",[430,704,705,728,757,805],{"__ignoreMap":5},[433,706,707,710,713,716,719,722,725],{"class":435,"line":436},[433,708,709],{"class":439},"interface",[433,711,712],{"class":473}," Task",[433,714,715],{"class":443},"\u003C",[433,717,718],{"class":473},"RT",[433,720,721],{"class":439}," =",[433,723,724],{"class":492}," unknown",[433,726,727],{"class":443},"> {\n",[433,729,730,733,736,739,741,743,746,749,751,753,755],{"class":435,"line":457},[433,731,732],{"class":595},"  meta",[433,734,735],{"class":439},"?:",[433,737,738],{"class":443}," { ",[433,740,675],{"class":595},[433,742,735],{"class":439},[433,744,745],{"class":492}," string",[433,747,748],{"class":443},"; ",[433,750,679],{"class":595},[433,752,735],{"class":439},[433,754,745],{"class":492},[433,756,637],{"class":443},[433,758,759,761,763,766,768,771,773,775,777,779,781,784,787,790,793,796,798,800,802],{"class":435,"line":464},[433,760,589],{"class":473},[433,762,616],{"class":443},[433,764,765],{"class":595},"event",[433,767,522],{"class":439},[433,769,770],{"class":473}," TaskEvent",[433,772,531],{"class":443},[433,774,522],{"class":439},[433,776,738],{"class":443},[433,778,698],{"class":595},[433,780,735],{"class":439},[433,782,783],{"class":473}," RT",[433,785,786],{"class":443}," } ",[433,788,789],{"class":439},"|",[433,791,792],{"class":473}," Promise",[433,794,795],{"class":443},"\u003C{ ",[433,797,698],{"class":595},[433,799,735],{"class":439},[433,801,783],{"class":473},[433,803,804],{"class":443}," }>;\n",[433,806,807],{"class":435,"line":480},[433,808,809],{"class":443},"}\n",[650,811,813],{"id":812},"taskevent",[430,814,694],{},[408,816,656,817,819,820,822],{},[430,818,687],{}," function receives a ",[430,821,694],{}," object with the following properties:",[662,824,825,832,843],{},[665,826,827,831],{},[535,828,829],{},[430,830,675],{},": The name of the task being executed.",[665,833,834,838,839,842],{},[535,835,836],{},[430,837,596],{},": An object (",[430,840,841],{},"Record\u003Cstring, unknown>",") containing any data passed to the task.",[665,844,845,849,850,853,854,857],{},[535,846,847],{},[430,848,602],{},": A ",[430,851,852],{},"TaskContext"," object (may include ",[430,855,856],{},"waitUntil"," depending on the runtime).",[423,859,861],{"className":425,"code":860,"language":428,"meta":5,"style":5},"interface TaskEvent {\n  name: string;\n  payload: TaskPayload;\n  context: TaskContext;\n}\n",[430,862,863,872,883,895,907],{"__ignoreMap":5},[433,864,865,867,869],{"class":435,"line":436},[433,866,709],{"class":439},[433,868,770],{"class":473},[433,870,871],{"class":443}," {\n",[433,873,874,877,879,881],{"class":435,"line":457},[433,875,876],{"class":595},"  name",[433,878,522],{"class":439},[433,880,745],{"class":492},[433,882,454],{"class":443},[433,884,885,888,890,893],{"class":435,"line":464},[433,886,887],{"class":595},"  payload",[433,889,522],{"class":439},[433,891,892],{"class":473}," TaskPayload",[433,894,454],{"class":443},[433,896,897,900,902,905],{"class":435,"line":480},[433,898,899],{"class":595},"  context",[433,901,522],{"class":439},[433,903,904],{"class":473}," TaskContext",[433,906,454],{"class":443},[433,908,909],{"class":435,"line":486},[433,910,809],{"class":443},[650,912,914],{"id":913},"registering-tasks-via-config","Registering tasks via config",[408,916,917],{},"In addition to file-based scanning, tasks can be registered directly in the Nitro config. This is useful for tasks provided by modules or pointing to custom handler paths.",[423,919,921],{"className":425,"code":920,"filename":427,"language":428,"meta":5,"style":5},"import { defineNitroConfig } from \"nitro/config\";\n\nexport default defineNitroConfig({\n  experimental: {\n    tasks: true\n  },\n  tasks: {\n    \"db:migrate\": {\n      handler: \"./tasks/custom-migrate.ts\",\n      description: \"Run database migrations\"\n    }\n  }\n})\n",[430,922,923,935,939,949,953,959,963,968,976,986,994,1000,1005],{"__ignoreMap":5},[433,924,925,927,929,931,933],{"class":435,"line":436},[433,926,440],{"class":439},[433,928,444],{"class":443},[433,930,447],{"class":439},[433,932,451],{"class":450},[433,934,454],{"class":443},[433,936,937],{"class":435,"line":457},[433,938,461],{"emptyLinePlaceholder":460},[433,940,941,943,945,947],{"class":435,"line":464},[433,942,467],{"class":439},[433,944,470],{"class":439},[433,946,474],{"class":473},[433,948,477],{"class":443},[433,950,951],{"class":435,"line":480},[433,952,483],{"class":443},[433,954,955,957],{"class":435,"line":486},[433,956,489],{"class":443},[433,958,493],{"class":492},[433,960,961],{"class":435,"line":496},[433,962,584],{"class":443},[433,964,965],{"class":435,"line":502},[433,966,967],{"class":443},"  tasks: {\n",[433,969,970,973],{"class":435,"line":625},[433,971,972],{"class":450},"    \"db:migrate\"",[433,974,975],{"class":443},": {\n",[433,977,978,981,984],{"class":435,"line":640},[433,979,980],{"class":443},"      handler: ",[433,982,983],{"class":450},"\"./tasks/custom-migrate.ts\"",[433,985,569],{"class":443},[433,987,988,991],{"class":435,"line":645},[433,989,990],{"class":443},"      description: ",[433,992,993],{"class":450},"\"Run database migrations\"\n",[433,995,997],{"class":435,"line":996},11,[433,998,999],{"class":443},"    }\n",[433,1001,1003],{"class":435,"line":1002},12,[433,1004,499],{"class":443},[433,1006,1008],{"class":435,"line":1007},13,[433,1009,505],{"class":443},[408,1011,1012,1013,1016,1017,1020],{},"If a task is both scanned from the ",[430,1014,1015],{},"tasks/"," directory and defined in the config, the config-defined ",[430,1018,1019],{},"handler"," takes precedence.",[400,1022,1024],{"id":1023},"scheduled-tasks","Scheduled tasks",[408,1026,1027],{},"You can define scheduled tasks using Nitro configuration to automatically run after each period of time.",[423,1029,1031],{"className":425,"code":1030,"filename":427,"language":428,"meta":5,"style":5},"import { defineNitroConfig } from \"nitro/config\";\n\nexport default defineNitroConfig({\n  scheduledTasks: {\n    // Run `cms:update` task every minute\n    '* * * * *': ['cms:update'],\n    // Run a single task (string shorthand)\n    '0 * * * *': 'db:cleanup'\n  }\n})\n",[430,1032,1033,1045,1049,1059,1064,1070,1084,1089,1100,1104],{"__ignoreMap":5},[433,1034,1035,1037,1039,1041,1043],{"class":435,"line":436},[433,1036,440],{"class":439},[433,1038,444],{"class":443},[433,1040,447],{"class":439},[433,1042,451],{"class":450},[433,1044,454],{"class":443},[433,1046,1047],{"class":435,"line":457},[433,1048,461],{"emptyLinePlaceholder":460},[433,1050,1051,1053,1055,1057],{"class":435,"line":464},[433,1052,467],{"class":439},[433,1054,470],{"class":439},[433,1056,474],{"class":473},[433,1058,477],{"class":443},[433,1060,1061],{"class":435,"line":480},[433,1062,1063],{"class":443},"  scheduledTasks: {\n",[433,1065,1066],{"class":435,"line":486},[433,1067,1069],{"class":1068},"sCsY4","    // Run `cms:update` task every minute\n",[433,1071,1072,1075,1078,1081],{"class":435,"line":496},[433,1073,1074],{"class":450},"    '* * * * *'",[433,1076,1077],{"class":443},": [",[433,1079,1080],{"class":450},"'cms:update'",[433,1082,1083],{"class":443},"],\n",[433,1085,1086],{"class":435,"line":502},[433,1087,1088],{"class":1068},"    // Run a single task (string shorthand)\n",[433,1090,1091,1094,1097],{"class":435,"line":625},[433,1092,1093],{"class":450},"    '0 * * * *'",[433,1095,1096],{"class":443},": ",[433,1098,1099],{"class":450},"'db:cleanup'\n",[433,1101,1102],{"class":435,"line":640},[433,1103,499],{"class":443},[433,1105,1106],{"class":435,"line":645},[433,1107,505],{"class":443},[408,1109,656,1110,1113],{},[430,1111,1112],{},"scheduledTasks"," config maps cron expressions to either a single task name (string) or an array of task names. When multiple tasks are assigned to the same cron expression, they run in parallel.",[1115,1116,1117],"tip",{},[408,1118,1119,1120,1125],{},"\nYou can use ",[412,1121,1124],{"href":1122,"rel":1123},"https://crontab.guru/",[416],"crontab.guru"," to easily generate and understand cron tab patterns.",[408,1127,1128,1129,1131,1132,1135,1136,1139],{},"When a scheduled task runs, it automatically receives a ",[430,1130,596],{}," with ",[430,1133,1134],{},"scheduledTime"," set to the current timestamp (",[430,1137,1138],{},"Date.now()",").",[650,1141,1143],{"id":1142},"platform-support","Platform support",[662,1145,1146,1185,1204,1226],{},[665,1147,1148,599,1153,599,1158,599,1163,599,1168,676,1173,1178,1179,1184],{},[535,1149,1150],{},[430,1151,1152],{},"dev",[535,1154,1155],{},[430,1156,1157],{},"node_server",[535,1159,1160],{},[430,1161,1162],{},"node_cluster",[535,1164,1165],{},[430,1166,1167],{},"node_middleware",[535,1169,1170],{},[430,1171,1172],{},"bun",[535,1174,1175],{},[430,1176,1177],{},"deno_server"," presets are supported with the ",[412,1180,1183],{"href":1181,"rel":1182},"https://croner.56k.guru/",[416],"croner"," engine.",[665,1186,1187,676,1192,1197,1198,1203],{},[535,1188,1189],{},[430,1190,1191],{},"cloudflare_module",[535,1193,1194],{},[430,1195,1196],{},"cloudflare_pages"," presets have native integration with ",[412,1199,1202],{"href":1200,"rel":1201},"https://developers.cloudflare.com/workers/configuration/cron-triggers/",[416],"Cron Triggers",". Nitro automatically generates the cron triggers in the wrangler config at build time - no manual wrangler setup required.",[665,1205,1206,1211,1212,1217,1218,1221,1222,1225],{},[535,1207,1208],{},[430,1209,1210],{},"vercel"," preset has native integration with ",[412,1213,1216],{"href":1214,"rel":1215},"https://vercel.com/docs/cron-jobs",[416],"Vercel Cron Jobs",". Nitro automatically generates the cron job configuration at build time - no manual ",[430,1219,1220],{},"vercel.json"," setup required. You can secure cron endpoints by setting the ",[430,1223,1224],{},"CRON_SECRET"," environment variable.",[665,1227,1228],{},"More presets (with native primitives support) are planned to be supported!",[400,1230,1232],{"id":1231},"waituntil",[430,1233,856],{},[408,1235,1236],{},"When running background tasks, you might want to make sure the server or worker waits until the task is done.",[408,1238,1239,1240,1243,1244,1248],{},"An optional ",[430,1241,1242],{},"context.waitUntil"," function ",[1245,1246,1247],"em",{},"might"," be available depending on the runtime.",[423,1250,1252],{"className":425,"code":1251,"language":428,"meta":5,"style":5},"export default defineTask({\n  run({ context }) {\n    const promise = fetch(...)\n    context.waitUntil?.(promise);\n    await promise;\n    return { result: \"Success\" };\n  },\n});\n",[430,1253,1254,1264,1274,1295,1305,1313,1323,1327],{"__ignoreMap":5},[433,1255,1256,1258,1260,1262],{"class":435,"line":436},[433,1257,467],{"class":439},[433,1259,470],{"class":439},[433,1261,551],{"class":473},[433,1263,477],{"class":443},[433,1265,1266,1268,1270,1272],{"class":435,"line":457},[433,1267,589],{"class":473},[433,1269,592],{"class":443},[433,1271,602],{"class":595},[433,1273,605],{"class":443},[433,1275,1276,1279,1282,1284,1287,1289,1292],{"class":435,"line":464},[433,1277,1278],{"class":439},"    const",[433,1280,1281],{"class":492}," promise",[433,1283,721],{"class":439},[433,1285,1286],{"class":473}," fetch",[433,1288,616],{"class":443},[433,1290,1291],{"class":439},"...",[433,1293,1294],{"class":443},")\n",[433,1296,1297,1300,1302],{"class":435,"line":480},[433,1298,1299],{"class":443},"    context.",[433,1301,856],{"class":473},[433,1303,1304],{"class":443},"?.(promise);\n",[433,1306,1307,1310],{"class":435,"line":486},[433,1308,1309],{"class":439},"    await",[433,1311,1312],{"class":443}," promise;\n",[433,1314,1315,1317,1319,1321],{"class":435,"line":496},[433,1316,628],{"class":439},[433,1318,631],{"class":443},[433,1320,634],{"class":450},[433,1322,637],{"class":443},[433,1324,1325],{"class":435,"line":502},[433,1326,584],{"class":443},[433,1328,1329],{"class":435,"line":625},[433,1330,648],{"class":443},[400,1332,1334],{"id":1333},"programmatically-run-tasks","Programmatically run tasks",[408,1336,1337,1338,1341,1342,1345],{},"To manually run tasks, you can use ",[430,1339,1340],{},"runTask(name, { payload?, context? })"," utility from ",[430,1343,1344],{},"nitro/task",".",[408,1347,1348],{},[535,1349,537],{},[423,1351,1354],{"className":425,"code":1352,"filename":1353,"language":428,"meta":5,"style":5},"import { defineHandler } from \"nitro\";\n\nexport default defineHandler(async (event) => {\n  // IMPORTANT: Authenticate user and validate payload!\n  const payload = Object.fromEntries(event.url.searchParams);\n  const { result } = await runTask(\"db:migrate\", { payload });\n\n  return { result };\n});\n","api/migrate.ts",[430,1355,1356,1370,1374,1401,1406,1425,1451,1455,1463],{"__ignoreMap":5},[433,1357,1358,1360,1363,1365,1368],{"class":435,"line":436},[433,1359,440],{"class":439},[433,1361,1362],{"class":443}," { defineHandler } ",[433,1364,447],{"class":439},[433,1366,1367],{"class":450}," \"nitro\"",[433,1369,454],{"class":443},[433,1371,1372],{"class":435,"line":457},[433,1373,461],{"emptyLinePlaceholder":460},[433,1375,1376,1378,1380,1383,1385,1388,1391,1393,1396,1399],{"class":435,"line":464},[433,1377,467],{"class":439},[433,1379,470],{"class":439},[433,1381,1382],{"class":473}," defineHandler",[433,1384,616],{"class":443},[433,1386,1387],{"class":439},"async",[433,1389,1390],{"class":443}," (",[433,1392,765],{"class":595},[433,1394,1395],{"class":443},") ",[433,1397,1398],{"class":439},"=>",[433,1400,871],{"class":443},[433,1402,1403],{"class":435,"line":480},[433,1404,1405],{"class":1068},"  // IMPORTANT: Authenticate user and validate payload!\n",[433,1407,1408,1411,1414,1416,1419,1422],{"class":435,"line":486},[433,1409,1410],{"class":439},"  const",[433,1412,1413],{"class":492}," payload",[433,1415,721],{"class":439},[433,1417,1418],{"class":443}," Object.",[433,1420,1421],{"class":473},"fromEntries",[433,1423,1424],{"class":443},"(event.url.searchParams);\n",[433,1426,1427,1429,1431,1433,1435,1438,1441,1444,1446,1448],{"class":435,"line":496},[433,1428,1410],{"class":439},[433,1430,738],{"class":443},[433,1432,698],{"class":492},[433,1434,786],{"class":443},[433,1436,1437],{"class":439},"=",[433,1439,1440],{"class":439}," await",[433,1442,1443],{"class":473}," runTask",[433,1445,616],{"class":443},[433,1447,566],{"class":450},[433,1449,1450],{"class":443},", { payload });\n",[433,1452,1453],{"class":435,"line":502},[433,1454,461],{"emptyLinePlaceholder":460},[433,1456,1457,1460],{"class":435,"line":625},[433,1458,1459],{"class":439},"  return",[433,1461,1462],{"class":443}," { result };\n",[433,1464,1465],{"class":435,"line":640},[433,1466,648],{"class":443},[650,1468,1470],{"id":1469},"error-handling","Error handling",[408,1472,1473,1476],{},[430,1474,1475],{},"runTask"," throws an HTTP error if:",[662,1478,1479,1485],{},[665,1480,1481,1482,1139],{},"The task does not exist (status ",[430,1483,1484],{},"404",[665,1486,1487,1488,1139],{},"The task has no handler implementation (status ",[430,1489,1490],{},"501",[408,1492,1493,1494,1496],{},"Any errors thrown inside the task's ",[430,1495,687],{}," function will propagate to the caller.",[400,1498,1500],{"id":1499},"run-tasks-with-dev-server","Run tasks with dev server",[408,1502,1503],{},"Nitro's built-in dev server exposes tasks to be easily executed without programmatic usage.",[650,1505,1507],{"id":1506},"using-api-routes","Using API routes",[1509,1510,1512],"h4",{"id":1511},"_nitrotasks",[430,1513,1514],{},"/_nitro/tasks",[408,1516,1517],{},"This endpoint returns a list of available task names and their meta.",[423,1519,1523],{"className":1520,"code":1521,"language":1522,"meta":5,"style":5},"language-json shiki shiki-themes github-light github-dark github-dark","// [GET] /_nitro/tasks\n{\n  \"tasks\": {\n    \"db:migrate\": {\n      \"description\": \"Run database migrations\"\n    },\n     \"cms:update\": {\n      \"description\": \"Update CMS content\"\n    }\n  },\n  \"scheduledTasks\": [\n    {\n      \"cron\": \"* * * * *\",\n      \"tasks\": [\n        \"cms:update\"\n      ]\n    }\n  ]\n}\n","json",[430,1524,1525,1530,1535,1542,1548,1557,1562,1569,1578,1582,1586,1594,1599,1611,1619,1625,1631,1636,1642],{"__ignoreMap":5},[433,1526,1527],{"class":435,"line":436},[433,1528,1529],{"class":1068},"// [GET] /_nitro/tasks\n",[433,1531,1532],{"class":435,"line":457},[433,1533,1534],{"class":443},"{\n",[433,1536,1537,1540],{"class":435,"line":464},[433,1538,1539],{"class":492},"  \"tasks\"",[433,1541,975],{"class":443},[433,1543,1544,1546],{"class":435,"line":480},[433,1545,972],{"class":492},[433,1547,975],{"class":443},[433,1549,1550,1553,1555],{"class":435,"line":486},[433,1551,1552],{"class":492},"      \"description\"",[433,1554,1096],{"class":443},[433,1556,993],{"class":450},[433,1558,1559],{"class":435,"line":496},[433,1560,1561],{"class":443},"    },\n",[433,1563,1564,1567],{"class":435,"line":502},[433,1565,1566],{"class":492},"     \"cms:update\"",[433,1568,975],{"class":443},[433,1570,1571,1573,1575],{"class":435,"line":625},[433,1572,1552],{"class":492},[433,1574,1096],{"class":443},[433,1576,1577],{"class":450},"\"Update CMS content\"\n",[433,1579,1580],{"class":435,"line":640},[433,1581,999],{"class":443},[433,1583,1584],{"class":435,"line":645},[433,1585,584],{"class":443},[433,1587,1588,1591],{"class":435,"line":996},[433,1589,1590],{"class":492},"  \"scheduledTasks\"",[433,1592,1593],{"class":443},": [\n",[433,1595,1596],{"class":435,"line":1002},[433,1597,1598],{"class":443},"    {\n",[433,1600,1601,1604,1606,1609],{"class":435,"line":1007},[433,1602,1603],{"class":492},"      \"cron\"",[433,1605,1096],{"class":443},[433,1607,1608],{"class":450},"\"* * * * *\"",[433,1610,569],{"class":443},[433,1612,1614,1617],{"class":435,"line":1613},14,[433,1615,1616],{"class":492},"      \"tasks\"",[433,1618,1593],{"class":443},[433,1620,1622],{"class":435,"line":1621},15,[433,1623,1624],{"class":450},"        \"cms:update\"\n",[433,1626,1628],{"class":435,"line":1627},16,[433,1629,1630],{"class":443},"      ]\n",[433,1632,1634],{"class":435,"line":1633},17,[433,1635,999],{"class":443},[433,1637,1639],{"class":435,"line":1638},18,[433,1640,1641],{"class":443},"  ]\n",[433,1643,1645],{"class":435,"line":1644},19,[433,1646,809],{"class":443},[1509,1648,1650],{"id":1649},"_nitrotasksname",[430,1651,1652],{},"/_nitro/tasks/:name",[408,1654,1655,1656,699],{},"This endpoint executes a task. You can provide a payload using both query parameters and body JSON payload. The payload sent in the JSON body payload must be under the ",[430,1657,1658],{},"\"payload\"",[1660,1661,1662,1746,1795],"code-group",{},[423,1663,1666],{"className":425,"code":1664,"filename":1665,"language":428,"meta":5,"style":5},"export default defineTask({\n  meta: {\n    name: \"echo:payload\",\n    description: \"Returns the provided payload\",\n  },\n  run({ payload, context }) {\n    console.log(\"Running echo task...\");\n    return { result: payload };\n  },\n});\n","tasks/echo/payload.ts",[430,1667,1668,1678,1682,1691,1700,1704,1718,1731,1738,1742],{"__ignoreMap":5},[433,1669,1670,1672,1674,1676],{"class":435,"line":436},[433,1671,467],{"class":439},[433,1673,470],{"class":439},[433,1675,551],{"class":473},[433,1677,477],{"class":443},[433,1679,1680],{"class":435,"line":457},[433,1681,558],{"class":443},[433,1683,1684,1686,1689],{"class":435,"line":464},[433,1685,563],{"class":443},[433,1687,1688],{"class":450},"\"echo:payload\"",[433,1690,569],{"class":443},[433,1692,1693,1695,1698],{"class":435,"line":480},[433,1694,574],{"class":443},[433,1696,1697],{"class":450},"\"Returns the provided payload\"",[433,1699,569],{"class":443},[433,1701,1702],{"class":435,"line":486},[433,1703,584],{"class":443},[433,1705,1706,1708,1710,1712,1714,1716],{"class":435,"line":496},[433,1707,589],{"class":473},[433,1709,592],{"class":443},[433,1711,596],{"class":595},[433,1713,599],{"class":443},[433,1715,602],{"class":595},[433,1717,605],{"class":443},[433,1719,1720,1722,1724,1726,1729],{"class":435,"line":502},[433,1721,610],{"class":443},[433,1723,613],{"class":473},[433,1725,616],{"class":443},[433,1727,1728],{"class":450},"\"Running echo task...\"",[433,1730,622],{"class":443},[433,1732,1733,1735],{"class":435,"line":625},[433,1734,628],{"class":439},[433,1736,1737],{"class":443}," { result: payload };\n",[433,1739,1740],{"class":435,"line":640},[433,1741,584],{"class":443},[433,1743,1744],{"class":435,"line":645},[433,1745,648],{"class":443},[423,1747,1750],{"className":1520,"code":1748,"filename":1749,"language":1522,"meta":5,"style":5},"// [GET] /_nitro/tasks/echo:payload?field=value&array=1&array=2\n{\n  \"field\": \"value\",\n  \"array\": [\"1\", \"2\"]\n}\n","GET",[430,1751,1752,1757,1761,1773,1791],{"__ignoreMap":5},[433,1753,1754],{"class":435,"line":436},[433,1755,1756],{"class":1068},"// [GET] /_nitro/tasks/echo:payload?field=value&array=1&array=2\n",[433,1758,1759],{"class":435,"line":457},[433,1760,1534],{"class":443},[433,1762,1763,1766,1768,1771],{"class":435,"line":464},[433,1764,1765],{"class":492},"  \"field\"",[433,1767,1096],{"class":443},[433,1769,1770],{"class":450},"\"value\"",[433,1772,569],{"class":443},[433,1774,1775,1778,1780,1783,1785,1788],{"class":435,"line":480},[433,1776,1777],{"class":492},"  \"array\"",[433,1779,1077],{"class":443},[433,1781,1782],{"class":450},"\"1\"",[433,1784,599],{"class":443},[433,1786,1787],{"class":450},"\"2\"",[433,1789,1790],{"class":443},"]\n",[433,1792,1793],{"class":435,"line":486},[433,1794,809],{"class":443},[423,1796,1799],{"className":1520,"code":1797,"filename":1798,"language":1522,"meta":5,"style":5},"/**\n * [POST] /_nitro/tasks/echo:payload?field=value\n * body: {\n *   \"payload\": {\n *     \"answer\": 42,\n *     \"nested\": {\n *       \"value\": true\n *     }\n *   }\n * }\n */\n{\n  \"field\": \"value\",\n  \"answer\": 42,\n  \"nested\": {\n    \"value\": true\n  }\n}\n","POST",[430,1800,1801,1806,1811,1816,1821,1826,1831,1836,1841,1846,1851,1856,1860,1870,1882,1889,1898,1902],{"__ignoreMap":5},[433,1802,1803],{"class":435,"line":436},[433,1804,1805],{"class":1068},"/**\n",[433,1807,1808],{"class":435,"line":457},[433,1809,1810],{"class":1068}," * [POST] /_nitro/tasks/echo:payload?field=value\n",[433,1812,1813],{"class":435,"line":464},[433,1814,1815],{"class":1068}," * body: {\n",[433,1817,1818],{"class":435,"line":480},[433,1819,1820],{"class":1068}," *   \"payload\": {\n",[433,1822,1823],{"class":435,"line":486},[433,1824,1825],{"class":1068}," *     \"answer\": 42,\n",[433,1827,1828],{"class":435,"line":496},[433,1829,1830],{"class":1068}," *     \"nested\": {\n",[433,1832,1833],{"class":435,"line":502},[433,1834,1835],{"class":1068}," *       \"value\": true\n",[433,1837,1838],{"class":435,"line":625},[433,1839,1840],{"class":1068}," *     }\n",[433,1842,1843],{"class":435,"line":640},[433,1844,1845],{"class":1068}," *   }\n",[433,1847,1848],{"class":435,"line":645},[433,1849,1850],{"class":1068}," * }\n",[433,1852,1853],{"class":435,"line":996},[433,1854,1855],{"class":1068}," */\n",[433,1857,1858],{"class":435,"line":1002},[433,1859,1534],{"class":443},[433,1861,1862,1864,1866,1868],{"class":435,"line":1007},[433,1863,1765],{"class":492},[433,1865,1096],{"class":443},[433,1867,1770],{"class":450},[433,1869,569],{"class":443},[433,1871,1872,1875,1877,1880],{"class":435,"line":1613},[433,1873,1874],{"class":492},"  \"answer\"",[433,1876,1096],{"class":443},[433,1878,1879],{"class":492},"42",[433,1881,569],{"class":443},[433,1883,1884,1887],{"class":435,"line":1621},[433,1885,1886],{"class":492},"  \"nested\"",[433,1888,975],{"class":443},[433,1890,1891,1894,1896],{"class":435,"line":1627},[433,1892,1893],{"class":492},"    \"value\"",[433,1895,1096],{"class":443},[433,1897,493],{"class":492},[433,1899,1900],{"class":435,"line":1633},[433,1901,499],{"class":443},[433,1903,1904],{"class":435,"line":1638},[433,1905,809],{"class":443},[1907,1908,1909],"note",{},[408,1910,1911],{},"\nThe JSON payload included in the body will overwrite the keys present in the query params.",[650,1913,1915],{"id":1914},"using-cli","Using CLI",[405,1917,1918],{},[408,1919,1920,1921,1924],{},"\nIt is only possible to run these commands while the ",[535,1922,1923],{},"dev server is running",". You should run them in a second terminal.",[1509,1926,1928],{"id":1927},"list-tasks","List tasks",[423,1930,1934],{"className":1931,"code":1932,"language":1933,"meta":5,"style":5},"language-sh shiki shiki-themes github-light github-dark github-dark","nitro task list\n","sh",[430,1935,1936],{"__ignoreMap":5},[433,1937,1938,1941,1944],{"class":435,"line":436},[433,1939,1940],{"class":473},"nitro",[433,1942,1943],{"class":450}," task",[433,1945,1946],{"class":450}," list\n",[1509,1948,1950],{"id":1949},"run-a-task","Run a task",[423,1952,1954],{"className":1931,"code":1953,"language":1933,"meta":5,"style":5},"nitro task run db:migrate --payload \"{}\"\n",[430,1955,1956],{"__ignoreMap":5},[433,1957,1958,1960,1962,1965,1968,1971],{"class":435,"line":436},[433,1959,1940],{"class":473},[433,1961,1943],{"class":450},[433,1963,1964],{"class":450}," run",[433,1966,1967],{"class":450}," db:migrate",[433,1969,1970],{"class":492}," --payload",[433,1972,1973],{"class":450}," \"{}\"\n",[408,1975,656,1976,1979],{},[430,1977,1978],{},"--payload"," flag accepts a JSON string that will be parsed and passed to the task. If the value is not a valid JSON object, the task runs without a payload.",[400,1981,1983],{"id":1982},"notes","Notes",[650,1985,1987],{"id":1986},"concurrency","Concurrency",[408,1989,1990,1991,1994],{},"Each task can have ",[535,1992,1993],{},"one running instance",". Calling a task of same name multiple times in parallel, results in calling it once and all callers will get the same return value.",[1907,1996,1997],{},[408,1998,1999],{},"\nNitro tasks can be running multiple times and in parallel.",[2001,2002,2003],"style",{},"html pre.shiki code .so5gQ, html code.shiki .so5gQ{--shiki-light:#D73A49;--shiki-default:#F97583;--shiki-dark:#F97583}html pre.shiki code .slsVL, html code.shiki .slsVL{--shiki-light:#24292E;--shiki-default:#E1E4E8;--shiki-dark:#E1E4E8}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 .sQHwn, html code.shiki .sQHwn{--shiki-light:#E36209;--shiki-default:#FFAB70;--shiki-dark:#FFAB70}html pre.shiki code .sCsY4, html code.shiki .sCsY4{--shiki-light:#6A737D;--shiki-default:#6A737D;--shiki-dark:#6A737D}",{"title":5,"searchDepth":457,"depth":457,"links":2005},[2006,2007,2012,2015,2016,2019,2023],{"id":402,"depth":457,"text":403},{"id":508,"depth":457,"text":509,"children":2008},[2009,2010,2011],{"id":652,"depth":464,"text":653},{"id":812,"depth":464,"text":694},{"id":913,"depth":464,"text":914},{"id":1023,"depth":457,"text":1024,"children":2013},[2014],{"id":1142,"depth":464,"text":1143},{"id":1231,"depth":457,"text":856},{"id":1333,"depth":457,"text":1334,"children":2017},[2018],{"id":1469,"depth":464,"text":1470},{"id":1499,"depth":457,"text":1500,"children":2020},[2021,2022],{"id":1506,"depth":464,"text":1507},{"id":1914,"depth":464,"text":1915},{"id":1982,"depth":457,"text":1983,"children":2024},[2025],{"id":1986,"depth":464,"text":1987},"Nitro tasks allow on-off operations in runtime.","md",{"icon":61},{"icon":61},{"title":58,"description":2026},"fcDQYqAY9pVnbTTI7IZmYH_zKMaVdoIh136BgP7RDMY",[2033,2035],{"title":53,"path":54,"stem":55,"description":2034,"icon":56,"children":-1},"Use plugins to extend Nitro's runtime behavior.",{"title":63,"path":64,"stem":65,"description":2036,"icon":66,"children":-1},"Use a server entry to create a global middleware that runs for all routes before they are matched.",1775834864651]