[{"data":1,"prerenderedAt":2995},["ShallowReactive",2],{"article-/topics/nuxt/nuxt-runtime-config-management":3,"related-nuxt":393,"content-query-loXmCobwF4":2706},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"date":10,"topic":5,"author":11,"tags":12,"image":18,"imageQuery":19,"pexelsPhotoId":20,"pexelsUrl":21,"featured":6,"readingTime":22,"body":23,"_type":387,"_id":388,"_source":389,"_file":390,"_stem":391,"_extension":392},"/topics/nuxt/nuxt-runtime-config-management","nuxt",false,"","Nuxt 运行时配置管理：多环境一致性、密钥边界与发布可控性","从 Nuxt runtimeConfig 机制出发，系统讲解多环境配置策略、公开变量与私密变量边界、常见配置反模式与上线检查清单，帮助团队降低环境差异导致的线上故障。","2026-04-12","HTMLPAGE 团队",[13,14,15,16,17],"Nuxt","runtimeConfig","DevOps","Environment","Security","/images/topics/nuxt/nuxt-runtime-config-management.jpg","cloud deployment configuration devops dashboard",6963944,"https://www.pexels.com/photo/a-man-looking-at-a-computer-screen-with-data-6963944/",14,{"type":24,"children":25,"toc":374},"root",[26,34,40,45,49,55,60,75,80,83,89,94,112,117,120,126,131,149,154,172,175,181,186,191,204,207,213,218,236,241,244,250,255,273,287,290,296,324,327,333,338,343],{"type":27,"tag":28,"props":29,"children":31},"element","h2",{"id":30},"nuxt-运行时配置管理多环境一致性密钥边界与发布可控性",[32],{"type":33,"value":8},"text",{"type":27,"tag":35,"props":36,"children":37},"p",{},[38],{"type":33,"value":39},"很多 Nuxt 项目的线上问题，不是代码逻辑错误，而是环境配置错位：测试环境能跑，生产环境报错；本地调用成功，部署后地址失效；密钥意外暴露到客户端。",{"type":27,"tag":35,"props":41,"children":42},{},[43],{"type":33,"value":44},"这些问题看似零碎，本质上都属于配置治理能力不足。",{"type":27,"tag":46,"props":47,"children":48},"hr",{},[],{"type":27,"tag":28,"props":50,"children":52},{"id":51},"_1-先区分配置边界",[53],{"type":33,"value":54},"1. 先区分配置边界",{"type":27,"tag":35,"props":56,"children":57},{},[58],{"type":33,"value":59},"Nuxt 配置治理最关键的一步是分清：",{"type":27,"tag":61,"props":62,"children":63},"ul",{},[64,70],{"type":27,"tag":65,"props":66,"children":67},"li",{},[68],{"type":33,"value":69},"哪些配置只能在服务端使用",{"type":27,"tag":65,"props":71,"children":72},{},[73],{"type":33,"value":74},"哪些配置允许暴露给客户端",{"type":27,"tag":35,"props":76,"children":77},{},[78],{"type":33,"value":79},"边界不清会直接带来安全与一致性问题。",{"type":27,"tag":46,"props":81,"children":82},{},[],{"type":27,"tag":28,"props":84,"children":86},{"id":85},"_2-runtimeconfig-的基本策略",[87],{"type":33,"value":88},"2. runtimeConfig 的基本策略",{"type":27,"tag":35,"props":90,"children":91},{},[92],{"type":33,"value":93},"推荐做法：",{"type":27,"tag":61,"props":95,"children":96},{},[97,102,107],{"type":27,"tag":65,"props":98,"children":99},{},[100],{"type":33,"value":101},"将私密配置放在 server-only 区域",{"type":27,"tag":65,"props":103,"children":104},{},[105],{"type":33,"value":106},"将前端可读配置放在 public 区域",{"type":27,"tag":65,"props":108,"children":109},{},[110],{"type":33,"value":111},"对每个配置项写清来源、默认值与用途",{"type":27,"tag":35,"props":113,"children":114},{},[115],{"type":33,"value":116},"如果配置项缺少语义说明，后续维护者很难判断改动风险。",{"type":27,"tag":46,"props":118,"children":119},{},[],{"type":27,"tag":28,"props":121,"children":123},{"id":122},"_3-多环境管理要避免隐式默认",[124],{"type":33,"value":125},"3. 多环境管理要避免“隐式默认”",{"type":27,"tag":35,"props":127,"children":128},{},[129],{"type":33,"value":130},"常见风险：",{"type":27,"tag":61,"props":132,"children":133},{},[134,139,144],{"type":27,"tag":65,"props":135,"children":136},{},[137],{"type":33,"value":138},"依赖本地默认值，线上却没有",{"type":27,"tag":65,"props":140,"children":141},{},[142],{"type":33,"value":143},"同名变量在不同环境含义不同",{"type":27,"tag":65,"props":145,"children":146},{},[147],{"type":33,"value":148},"临时变量长期残留",{"type":27,"tag":35,"props":150,"children":151},{},[152],{"type":33,"value":153},"更稳的策略是：",{"type":27,"tag":61,"props":155,"children":156},{},[157,162,167],{"type":27,"tag":65,"props":158,"children":159},{},[160],{"type":33,"value":161},"环境变量清单化",{"type":27,"tag":65,"props":163,"children":164},{},[165],{"type":33,"value":166},"启动时做必要字段校验",{"type":27,"tag":65,"props":168,"children":169},{},[170],{"type":33,"value":171},"发布流水线增加配置检查步骤",{"type":27,"tag":46,"props":173,"children":174},{},[],{"type":27,"tag":28,"props":176,"children":178},{"id":177},"_4-失败案例把私钥放进-public-配置导致泄露",[179],{"type":33,"value":180},"4. 失败案例：把私钥放进 public 配置导致泄露",{"type":27,"tag":35,"props":182,"children":183},{},[184],{"type":33,"value":185},"这类事故并不少见。团队把“客户端也要用”的理解扩大化，结果把本应仅服务端使用的密钥放进了 public。",{"type":27,"tag":35,"props":187,"children":188},{},[189],{"type":33,"value":190},"原则很简单：",{"type":27,"tag":61,"props":192,"children":193},{},[194,199],{"type":27,"tag":65,"props":195,"children":196},{},[197],{"type":33,"value":198},"只要不需要浏览器直接读取，就不要放 public",{"type":27,"tag":65,"props":200,"children":201},{},[202],{"type":33,"value":203},"客户端需要的能力，优先通过服务端代理暴露",{"type":27,"tag":46,"props":205,"children":206},{},[],{"type":27,"tag":28,"props":208,"children":210},{"id":209},"_5-配置与发布流程绑定",[211],{"type":33,"value":212},"5. 配置与发布流程绑定",{"type":27,"tag":35,"props":214,"children":215},{},[216],{"type":33,"value":217},"把配置管理纳入发布流程，至少包含：",{"type":27,"tag":61,"props":219,"children":220},{},[221,226,231],{"type":27,"tag":65,"props":222,"children":223},{},[224],{"type":33,"value":225},"环境变量完整性校验",{"type":27,"tag":65,"props":227,"children":228},{},[229],{"type":33,"value":230},"配置变更审计记录",{"type":27,"tag":65,"props":232,"children":233},{},[234],{"type":33,"value":235},"关键配置回滚方案",{"type":27,"tag":35,"props":237,"children":238},{},[239],{"type":33,"value":240},"这样配置不再是“上线当天临时手动操作”，而是受控流程。",{"type":27,"tag":46,"props":242,"children":243},{},[],{"type":27,"tag":28,"props":245,"children":247},{"id":246},"_6-与-nuxt-server-routes-和外部服务协同",[248],{"type":33,"value":249},"6. 与 Nuxt Server Routes 和外部服务协同",{"type":27,"tag":35,"props":251,"children":252},{},[253],{"type":33,"value":254},"runtimeConfig 常用于：",{"type":27,"tag":61,"props":256,"children":257},{},[258,263,268],{"type":27,"tag":65,"props":259,"children":260},{},[261],{"type":33,"value":262},"外部 API base URL",{"type":27,"tag":65,"props":264,"children":265},{},[266],{"type":33,"value":267},"鉴权密钥",{"type":27,"tag":65,"props":269,"children":270},{},[271],{"type":33,"value":272},"监控与回调地址",{"type":27,"tag":35,"props":274,"children":275},{},[276,278,285],{"type":33,"value":277},"这些配置应通过统一读取入口使用，避免在各文件散落 ",{"type":27,"tag":279,"props":280,"children":282},"code",{"className":281},[],[283],{"type":33,"value":284},"process.env",{"type":33,"value":286}," 直接访问。",{"type":27,"tag":46,"props":288,"children":289},{},[],{"type":27,"tag":28,"props":291,"children":293},{"id":292},"_7-checklist运行时配置是否可控",[294],{"type":33,"value":295},"7. Checklist：运行时配置是否可控",{"type":27,"tag":61,"props":297,"children":298},{},[299,304,309,314,319],{"type":27,"tag":65,"props":300,"children":301},{},[302],{"type":33,"value":303},"是否明确区分 public 与 private",{"type":27,"tag":65,"props":305,"children":306},{},[307],{"type":33,"value":308},"是否有环境变量清单与说明",{"type":27,"tag":65,"props":310,"children":311},{},[312],{"type":33,"value":313},"是否在启动或构建阶段做配置校验",{"type":27,"tag":65,"props":315,"children":316},{},[317],{"type":33,"value":318},"是否禁止在业务代码中散落读取原始环境变量",{"type":27,"tag":65,"props":320,"children":321},{},[322],{"type":33,"value":323},"是否具备配置变更审计与回滚能力",{"type":27,"tag":46,"props":325,"children":326},{},[],{"type":27,"tag":28,"props":328,"children":330},{"id":329},"_8-结论",[331],{"type":33,"value":332},"8. 结论",{"type":27,"tag":35,"props":334,"children":335},{},[336],{"type":33,"value":337},"Nuxt 运行时配置治理的核心价值，是让多环境行为可预测、密钥边界可控、发布过程可审计。把配置当成工程资产，而不是部署细节，才能避免反复踩同一类线上坑。",{"type":27,"tag":35,"props":339,"children":340},{},[341],{"type":33,"value":342},"进一步阅读：",{"type":27,"tag":61,"props":344,"children":345},{},[346,356,365],{"type":27,"tag":65,"props":347,"children":348},{},[349],{"type":27,"tag":350,"props":351,"children":353},"a",{"href":352},"/topics/nuxt/nuxt-env-config-guide",[354],{"type":33,"value":355},"Nuxt 环境配置指南",{"type":27,"tag":65,"props":357,"children":358},{},[359],{"type":27,"tag":350,"props":360,"children":362},{"href":361},"/topics/nuxt/nuxt-server-routes-complete-guide",[363],{"type":33,"value":364},"Nuxt Server Routes 完整指南",{"type":27,"tag":65,"props":366,"children":367},{},[368],{"type":27,"tag":350,"props":369,"children":371},{"href":370},"/topics/frontend/error-handling-logging-guide",[372],{"type":33,"value":373},"前端错误处理与日志治理",{"title":7,"searchDepth":375,"depth":375,"links":376},3,[377,379,380,381,382,383,384,385,386],{"id":30,"depth":378,"text":8},2,{"id":51,"depth":378,"text":54},{"id":85,"depth":378,"text":88},{"id":122,"depth":378,"text":125},{"id":177,"depth":378,"text":180},{"id":209,"depth":378,"text":212},{"id":246,"depth":378,"text":249},{"id":292,"depth":378,"text":295},{"id":329,"depth":378,"text":332},"markdown","content:topics:nuxt:nuxt-runtime-config-management.md","content","topics/nuxt/nuxt-runtime-config-management.md","topics/nuxt/nuxt-runtime-config-management","md",[394,1381,2165],{"_path":395,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":396,"description":397,"date":398,"topic":5,"author":11,"tags":399,"image":405,"featured":406,"readingTime":407,"body":408,"_type":387,"_id":1378,"_source":389,"_file":1379,"_stem":1380,"_extension":392},"/topics/nuxt/nitro-engine-deep-dive","Nitro 引擎深度剖析","讲透 Nuxt/Nitro 的运行时模型、路由与中间件、存储层与缓存、部署适配与性能调优，帮助你把服务端能力当成可控的工程系统。","2026-01-20",[13,400,401,402,403,404],"Nitro","SSR","Serverless","Edge","缓存","/images/topics/nuxt/nitro.jpg",true,21,{"type":24,"children":409,"toc":1346},[410,415,428,433,491,496,501,504,510,515,539,544,562,565,571,576,599,604,607,629,641,659,670,683,689,712,715,721,726,757,762,775,778,784,796,809,814,832,837,850,853,859,864,882,888,907,913,918,923,952,955,961,966,984,989,1007,1013,1026,1032,1045,1051,1064,1069,1082,1085,1091,1097,1110,1116,1129,1135,1148,1151,1157,1162,1185,1190,1203,1206,1212,1217,1275,1280,1298,1301,1306,1318,1323],{"type":27,"tag":28,"props":411,"children":413},{"id":412},"nitro-引擎深度剖析",[414],{"type":33,"value":396},{"type":27,"tag":35,"props":416,"children":417},{},[418,420,426],{"type":33,"value":419},"在 Nuxt 3/4 的体系里，Nitro 不是“一个服务器”，而是一套",{"type":27,"tag":421,"props":422,"children":423},"strong",{},[424],{"type":33,"value":425},"可移植的服务端运行时与构建产物规范",{"type":33,"value":427},"。",{"type":27,"tag":35,"props":429,"children":430},{},[431],{"type":33,"value":432},"它把你在开发时写的：",{"type":27,"tag":61,"props":434,"children":435},{},[436,447,458,469,480],{"type":27,"tag":65,"props":437,"children":438},{},[439,445],{"type":27,"tag":279,"props":440,"children":442},{"className":441},[],[443],{"type":33,"value":444},"server/api/*",{"type":33,"value":446},"（API 路由）",{"type":27,"tag":65,"props":448,"children":449},{},[450,456],{"type":27,"tag":279,"props":451,"children":453},{"className":452},[],[454],{"type":33,"value":455},"server/routes/*",{"type":33,"value":457},"（更底层路由）",{"type":27,"tag":65,"props":459,"children":460},{},[461,467],{"type":27,"tag":279,"props":462,"children":464},{"className":463},[],[465],{"type":33,"value":466},"server/middleware/*",{"type":33,"value":468},"（中间件）",{"type":27,"tag":65,"props":470,"children":471},{},[472,478],{"type":27,"tag":279,"props":473,"children":475},{"className":474},[],[476],{"type":33,"value":477},"server/plugins/*",{"type":33,"value":479},"（启动插件）",{"type":27,"tag":65,"props":481,"children":482},{},[483,489],{"type":27,"tag":279,"props":484,"children":486},{"className":485},[],[487],{"type":33,"value":488},"storage",{"type":33,"value":490},"（KV/文件/内存等存储抽象）",{"type":27,"tag":35,"props":492,"children":493},{},[494],{"type":33,"value":495},"统一编译成一个可以部署到多种环境的产物：Node Server、Serverless、Edge（取决于适配器与能力集）。",{"type":27,"tag":35,"props":497,"children":498},{},[499],{"type":33,"value":500},"这篇文章按“你要在生产上稳定运行”的视角，拆解 Nitro 的关键构件，并给出性能与可观测性落地建议。",{"type":27,"tag":46,"props":502,"children":503},{},[],{"type":27,"tag":28,"props":505,"children":507},{"id":506},"_1-nitro-的定位从-nuxt-ssr-到通用服务端运行时",[508],{"type":33,"value":509},"1. Nitro 的定位：从 Nuxt SSR 到“通用服务端运行时”",{"type":27,"tag":35,"props":511,"children":512},{},[513],{"type":33,"value":514},"Nitro 解决两类问题：",{"type":27,"tag":516,"props":517,"children":518},"ol",{},[519,529],{"type":27,"tag":65,"props":520,"children":521},{},[522,527],{"type":27,"tag":421,"props":523,"children":524},{},[525],{"type":33,"value":526},"运行时统一",{"type":33,"value":528},"：开发/生产环境一致的请求处理模型",{"type":27,"tag":65,"props":530,"children":531},{},[532,537],{"type":27,"tag":421,"props":533,"children":534},{},[535],{"type":33,"value":536},"部署可移植",{"type":33,"value":538},"：同一套代码可输出到不同部署目标",{"type":27,"tag":35,"props":540,"children":541},{},[542],{"type":33,"value":543},"你可以把 Nitro 看作 Nuxt 的“服务端内核”，而 Nuxt 只是围绕它提供：",{"type":27,"tag":61,"props":545,"children":546},{},[547,552,557],{"type":27,"tag":65,"props":548,"children":549},{},[550],{"type":33,"value":551},"视图渲染（SSR/RSC 相关能力）",{"type":27,"tag":65,"props":553,"children":554},{},[555],{"type":33,"value":556},"资源构建（Vite/Webpack）",{"type":27,"tag":65,"props":558,"children":559},{},[560],{"type":33,"value":561},"路由与数据获取的上层抽象",{"type":27,"tag":46,"props":563,"children":564},{},[],{"type":27,"tag":28,"props":566,"children":568},{"id":567},"_2-请求生命周期一次请求在-nitro-里怎么走",[569],{"type":33,"value":570},"2. 请求生命周期：一次请求在 Nitro 里怎么走？",{"type":27,"tag":35,"props":572,"children":573},{},[574],{"type":33,"value":575},"简化后的请求链路：",{"type":27,"tag":516,"props":577,"children":578},{},[579,584,589,594],{"type":27,"tag":65,"props":580,"children":581},{},[582],{"type":33,"value":583},"入口适配器接收请求（Node/Serverless/Edge）",{"type":27,"tag":65,"props":585,"children":586},{},[587],{"type":33,"value":588},"进入 Nitro 的 H3 请求处理器（统一事件模型）",{"type":27,"tag":65,"props":590,"children":591},{},[592],{"type":33,"value":593},"依次执行：中间件 → 路由匹配 → handler",{"type":27,"tag":65,"props":595,"children":596},{},[597],{"type":33,"value":598},"写回响应（含 headers、缓存策略、流式输出等）",{"type":27,"tag":35,"props":600,"children":601},{},[602],{"type":33,"value":603},"关键点：Nitro 用统一的事件对象承载请求上下文，这让你在不同部署目标下写出的 server 代码保持一致。",{"type":27,"tag":46,"props":605,"children":606},{},[],{"type":27,"tag":28,"props":608,"children":610},{"id":609},"_3-路由系统serverapi-与-serverroutes-的区别",[611,613,619,621,627],{"type":33,"value":612},"3. 路由系统：",{"type":27,"tag":279,"props":614,"children":616},{"className":615},[],[617],{"type":33,"value":618},"server/api",{"type":33,"value":620}," 与 ",{"type":27,"tag":279,"props":622,"children":624},{"className":623},[],[625],{"type":33,"value":626},"server/routes",{"type":33,"value":628}," 的区别",{"type":27,"tag":630,"props":631,"children":633},"h3",{"id":632},"_31-serverapi",[634,636],{"type":33,"value":635},"3.1 ",{"type":27,"tag":279,"props":637,"children":639},{"className":638},[],[640],{"type":33,"value":444},{"type":27,"tag":61,"props":642,"children":643},{},[644,649,654],{"type":27,"tag":65,"props":645,"children":646},{},[647],{"type":33,"value":648},"面向 API 的约定式目录",{"type":27,"tag":65,"props":650,"children":651},{},[652],{"type":33,"value":653},"通常返回 JSON",{"type":27,"tag":65,"props":655,"children":656},{},[657],{"type":33,"value":658},"与 Nuxt 的开发体验高度整合",{"type":27,"tag":630,"props":660,"children":662},{"id":661},"_32-serverroutes",[663,665],{"type":33,"value":664},"3.2 ",{"type":27,"tag":279,"props":666,"children":668},{"className":667},[],[669],{"type":33,"value":455},{"type":27,"tag":61,"props":671,"children":672},{},[673,678],{"type":27,"tag":65,"props":674,"children":675},{},[676],{"type":33,"value":677},"更底层，更贴近“HTTP 路由”",{"type":27,"tag":65,"props":679,"children":680},{},[681],{"type":33,"value":682},"更适合做：Webhook、回调、代理、特殊 content-type",{"type":27,"tag":630,"props":684,"children":686},{"id":685},"_33-实践建议",[687],{"type":33,"value":688},"3.3 实践建议",{"type":27,"tag":61,"props":690,"children":691},{},[692,702],{"type":27,"tag":65,"props":693,"children":694},{},[695,697],{"type":33,"value":696},"普通业务 API：优先 ",{"type":27,"tag":279,"props":698,"children":700},{"className":699},[],[701],{"type":33,"value":618},{"type":27,"tag":65,"props":703,"children":704},{},[705,707],{"type":33,"value":706},"需要更强控制（stream、代理、非 JSON）：用 ",{"type":27,"tag":279,"props":708,"children":710},{"className":709},[],[711],{"type":33,"value":626},{"type":27,"tag":46,"props":713,"children":714},{},[],{"type":27,"tag":28,"props":716,"children":718},{"id":717},"_4-中间件全局逻辑的正确放置",[719],{"type":33,"value":720},"4. 中间件：全局逻辑的正确放置",{"type":27,"tag":35,"props":722,"children":723},{},[724],{"type":33,"value":725},"Nitro 中的中间件通常用于：",{"type":27,"tag":61,"props":727,"children":728},{},[729,734,747,752],{"type":27,"tag":65,"props":730,"children":731},{},[732],{"type":33,"value":733},"鉴权/鉴别请求来源",{"type":27,"tag":65,"props":735,"children":736},{},[737,739,745],{"type":33,"value":738},"注入 ",{"type":27,"tag":279,"props":740,"children":742},{"className":741},[],[743],{"type":33,"value":744},"requestId",{"type":33,"value":746},"、trace 信息",{"type":27,"tag":65,"props":748,"children":749},{},[750],{"type":33,"value":751},"统一错误处理与日志",{"type":27,"tag":65,"props":753,"children":754},{},[755],{"type":33,"value":756},"基础安全 headers",{"type":27,"tag":35,"props":758,"children":759},{},[760],{"type":33,"value":761},"一个推荐的中间件职责边界：",{"type":27,"tag":61,"props":763,"children":764},{},[765,770],{"type":27,"tag":65,"props":766,"children":767},{},[768],{"type":33,"value":769},"中间件只做“横切关注点”",{"type":27,"tag":65,"props":771,"children":772},{},[773],{"type":33,"value":774},"不做具体业务（避免耦合与隐式依赖）",{"type":27,"tag":46,"props":776,"children":777},{},[],{"type":27,"tag":28,"props":779,"children":781},{"id":780},"_5-storage-抽象让缓存与数据存取可替换",[782],{"type":33,"value":783},"5. Storage 抽象：让缓存与数据存取可替换",{"type":27,"tag":35,"props":785,"children":786},{},[787,789,794],{"type":33,"value":788},"Nitro 的一个被低估的能力是 ",{"type":27,"tag":279,"props":790,"children":792},{"className":791},[],[793],{"type":33,"value":488},{"type":33,"value":795},"：",{"type":27,"tag":61,"props":797,"children":798},{},[799,804],{"type":27,"tag":65,"props":800,"children":801},{},[802],{"type":33,"value":803},"提供 KV 风格 API",{"type":27,"tag":65,"props":805,"children":806},{},[807],{"type":33,"value":808},"可接入内存、文件、Redis 等（取决于配置与环境）",{"type":27,"tag":35,"props":810,"children":811},{},[812],{"type":33,"value":813},"你可以用它做：",{"type":27,"tag":61,"props":815,"children":816},{},[817,822,827],{"type":27,"tag":65,"props":818,"children":819},{},[820],{"type":33,"value":821},"缓存（页面片段、API 结果）",{"type":27,"tag":65,"props":823,"children":824},{},[825],{"type":33,"value":826},"限流计数器",{"type":27,"tag":65,"props":828,"children":829},{},[830],{"type":33,"value":831},"临时会话信息",{"type":27,"tag":35,"props":833,"children":834},{},[835],{"type":33,"value":836},"设计原则：",{"type":27,"tag":61,"props":838,"children":839},{},[840,845],{"type":27,"tag":65,"props":841,"children":842},{},[843],{"type":33,"value":844},"把 storage 当成“可失效缓存”，不要当主数据库",{"type":27,"tag":65,"props":846,"children":847},{},[848],{"type":33,"value":849},"明确 TTL 与清理策略",{"type":27,"tag":46,"props":851,"children":852},{},[],{"type":27,"tag":28,"props":854,"children":856},{"id":855},"_6-缓存策略把快变成可控的工程能力",[857],{"type":33,"value":858},"6. 缓存策略：把“快”变成可控的工程能力",{"type":27,"tag":35,"props":860,"children":861},{},[862],{"type":33,"value":863},"Nitro 里的缓存往往涉及三层：",{"type":27,"tag":516,"props":865,"children":866},{},[867,872,877],{"type":27,"tag":65,"props":868,"children":869},{},[870],{"type":33,"value":871},"CDN 缓存（边缘）",{"type":27,"tag":65,"props":873,"children":874},{},[875],{"type":33,"value":876},"Nitro 运行时缓存（storage）",{"type":27,"tag":65,"props":878,"children":879},{},[880],{"type":33,"value":881},"上游服务缓存（数据库/服务端）",{"type":27,"tag":630,"props":883,"children":885},{"id":884},"_61-api-缓存的推荐做法",[886],{"type":33,"value":887},"6.1 API 缓存的推荐做法",{"type":27,"tag":61,"props":889,"children":890},{},[891,902],{"type":27,"tag":65,"props":892,"children":893},{},[894,896],{"type":33,"value":895},"对“读多写少”的接口做 ",{"type":27,"tag":279,"props":897,"children":899},{"className":898},[],[900],{"type":33,"value":901},"stale-while-revalidate",{"type":27,"tag":65,"props":903,"children":904},{},[905],{"type":33,"value":906},"缓存 key 必须包含：用户态/语言/地区/权限等关键维度",{"type":27,"tag":630,"props":908,"children":910},{"id":909},"_62-不要缓存带用户身份的响应除非你非常确定",[911],{"type":33,"value":912},"6.2 不要缓存“带用户身份”的响应（除非你非常确定）",{"type":27,"tag":35,"props":914,"children":915},{},[916],{"type":33,"value":917},"最容易出事故的是把 A 用户的数据缓存给 B 用户。",{"type":27,"tag":35,"props":919,"children":920},{},[921],{"type":33,"value":922},"建议：",{"type":27,"tag":61,"props":924,"children":925},{},[926,931],{"type":27,"tag":65,"props":927,"children":928},{},[929],{"type":33,"value":930},"默认对用户态接口不缓存",{"type":27,"tag":65,"props":932,"children":933},{},[934,936,942,944,950],{"type":33,"value":935},"必须缓存时，key 中加入 ",{"type":27,"tag":279,"props":937,"children":939},{"className":938},[],[940],{"type":33,"value":941},"userId",{"type":33,"value":943}," 或 ",{"type":27,"tag":279,"props":945,"children":947},{"className":946},[],[948],{"type":33,"value":949},"session",{"type":33,"value":951}," 维度",{"type":27,"tag":46,"props":953,"children":954},{},[],{"type":27,"tag":28,"props":956,"children":958},{"id":957},"_7-部署适配为什么同一套代码能跑在不同环境",[959],{"type":33,"value":960},"7. 部署适配：为什么同一套代码能跑在不同环境？",{"type":27,"tag":35,"props":962,"children":963},{},[964],{"type":33,"value":965},"Nitro 的部署产物通常包含：",{"type":27,"tag":61,"props":967,"children":968},{},[969,974,979],{"type":27,"tag":65,"props":970,"children":971},{},[972],{"type":33,"value":973},"编译后的 server bundle",{"type":27,"tag":65,"props":975,"children":976},{},[977],{"type":33,"value":978},"路由清单与运行时配置",{"type":27,"tag":65,"props":980,"children":981},{},[982],{"type":33,"value":983},"静态资源与预渲染结果（如果启用）",{"type":27,"tag":35,"props":985,"children":986},{},[987],{"type":33,"value":988},"在不同目标下的差异主要在：",{"type":27,"tag":61,"props":990,"children":991},{},[992,997,1002],{"type":27,"tag":65,"props":993,"children":994},{},[995],{"type":33,"value":996},"运行时能力（Node API 是否可用）",{"type":27,"tag":65,"props":998,"children":999},{},[1000],{"type":33,"value":1001},"冷启动与并发模型",{"type":27,"tag":65,"props":1003,"children":1004},{},[1005],{"type":33,"value":1006},"文件系统是否可写",{"type":27,"tag":630,"props":1008,"children":1010},{"id":1009},"_71-node-server",[1011],{"type":33,"value":1012},"7.1 Node Server",{"type":27,"tag":61,"props":1014,"children":1015},{},[1016,1021],{"type":27,"tag":65,"props":1017,"children":1018},{},[1019],{"type":33,"value":1020},"能力最完整",{"type":27,"tag":65,"props":1022,"children":1023},{},[1024],{"type":33,"value":1025},"适合长连接、websocket（需配合平台）",{"type":27,"tag":630,"props":1027,"children":1029},{"id":1028},"_72-serverless",[1030],{"type":33,"value":1031},"7.2 Serverless",{"type":27,"tag":61,"props":1033,"children":1034},{},[1035,1040],{"type":27,"tag":65,"props":1036,"children":1037},{},[1038],{"type":33,"value":1039},"冷启动成本、执行时长限制",{"type":27,"tag":65,"props":1041,"children":1042},{},[1043],{"type":33,"value":1044},"更适合 API 型工作负载",{"type":27,"tag":630,"props":1046,"children":1048},{"id":1047},"_73-edge",[1049],{"type":33,"value":1050},"7.3 Edge",{"type":27,"tag":61,"props":1052,"children":1053},{},[1054,1059],{"type":27,"tag":65,"props":1055,"children":1056},{},[1057],{"type":33,"value":1058},"延迟更低",{"type":27,"tag":65,"props":1060,"children":1061},{},[1062],{"type":33,"value":1063},"运行时限制更严格（例如 Node API 不可用）",{"type":27,"tag":35,"props":1065,"children":1066},{},[1067],{"type":33,"value":1068},"实践建议：",{"type":27,"tag":61,"props":1070,"children":1071},{},[1072,1077],{"type":27,"tag":65,"props":1073,"children":1074},{},[1075],{"type":33,"value":1076},"如果你依赖复杂 Node 能力（例如图像处理、原生模块），优先 Node/Serverless",{"type":27,"tag":65,"props":1078,"children":1079},{},[1080],{"type":33,"value":1081},"如果你追求极致延迟且逻辑简单，考虑 Edge",{"type":27,"tag":46,"props":1083,"children":1084},{},[],{"type":27,"tag":28,"props":1086,"children":1088},{"id":1087},"_8-性能调优nitro-侧你能做什么",[1089],{"type":33,"value":1090},"8. 性能调优：Nitro 侧你能做什么？",{"type":27,"tag":630,"props":1092,"children":1094},{"id":1093},"_81-减少阻塞-io",[1095],{"type":33,"value":1096},"8.1 减少阻塞 I/O",{"type":27,"tag":61,"props":1098,"children":1099},{},[1100,1105],{"type":27,"tag":65,"props":1101,"children":1102},{},[1103],{"type":33,"value":1104},"避免请求内做同步文件读写",{"type":27,"tag":65,"props":1106,"children":1107},{},[1108],{"type":33,"value":1109},"对“配置/规则”等可缓存数据做启动预热",{"type":27,"tag":630,"props":1111,"children":1113},{"id":1112},"_82-控制上游依赖",[1114],{"type":33,"value":1115},"8.2 控制上游依赖",{"type":27,"tag":61,"props":1117,"children":1118},{},[1119,1124],{"type":27,"tag":65,"props":1120,"children":1121},{},[1122],{"type":33,"value":1123},"给外部请求设超时（例如 2~3s）",{"type":27,"tag":65,"props":1125,"children":1126},{},[1127],{"type":33,"value":1128},"加重试要谨慎（避免雪崩）",{"type":27,"tag":630,"props":1130,"children":1132},{"id":1131},"_83-响应体积与压缩",[1133],{"type":33,"value":1134},"8.3 响应体积与压缩",{"type":27,"tag":61,"props":1136,"children":1137},{},[1138,1143],{"type":27,"tag":65,"props":1139,"children":1140},{},[1141],{"type":33,"value":1142},"JSON 输出控制字段",{"type":27,"tag":65,"props":1144,"children":1145},{},[1146],{"type":33,"value":1147},"开启 gzip/br",{"type":27,"tag":46,"props":1149,"children":1150},{},[],{"type":27,"tag":28,"props":1152,"children":1154},{"id":1153},"_9-可观测性没有观测就没有稳定",[1155],{"type":33,"value":1156},"9. 可观测性：没有观测就没有“稳定”",{"type":27,"tag":35,"props":1158,"children":1159},{},[1160],{"type":33,"value":1161},"建议 Nitro 侧最小可观测集合：",{"type":27,"tag":61,"props":1163,"children":1164},{},[1165,1170,1175,1180],{"type":27,"tag":65,"props":1166,"children":1167},{},[1168],{"type":33,"value":1169},"requestId/traceId",{"type":27,"tag":65,"props":1171,"children":1172},{},[1173],{"type":33,"value":1174},"关键路由耗时（p50/p95）",{"type":27,"tag":65,"props":1176,"children":1177},{},[1178],{"type":33,"value":1179},"错误率（按路由/按状态码）",{"type":27,"tag":65,"props":1181,"children":1182},{},[1183],{"type":33,"value":1184},"上游依赖耗时（DB/HTTP）",{"type":27,"tag":35,"props":1186,"children":1187},{},[1188],{"type":33,"value":1189},"落地方式：",{"type":27,"tag":61,"props":1191,"children":1192},{},[1193,1198],{"type":27,"tag":65,"props":1194,"children":1195},{},[1196],{"type":33,"value":1197},"在中间件注入 requestId",{"type":27,"tag":65,"props":1199,"children":1200},{},[1201],{"type":33,"value":1202},"在统一错误处理处记录结构化日志",{"type":27,"tag":46,"props":1204,"children":1205},{},[],{"type":27,"tag":28,"props":1207,"children":1209},{"id":1208},"_10-一个推荐的-nitro-工程结构",[1210],{"type":33,"value":1211},"10. 一个推荐的 Nitro 工程结构",{"type":27,"tag":35,"props":1213,"children":1214},{},[1215],{"type":33,"value":1216},"在 Nuxt 项目里，你可以这样组织服务端代码：",{"type":27,"tag":61,"props":1218,"children":1219},{},[1220,1231,1242,1253,1264],{"type":27,"tag":65,"props":1221,"children":1222},{},[1223,1229],{"type":27,"tag":279,"props":1224,"children":1226},{"className":1225},[],[1227],{"type":33,"value":1228},"server/middleware/",{"type":33,"value":1230},"：鉴权、日志、headers、rate limit",{"type":27,"tag":65,"props":1232,"children":1233},{},[1234,1240],{"type":27,"tag":279,"props":1235,"children":1237},{"className":1236},[],[1238],{"type":33,"value":1239},"server/api/",{"type":33,"value":1241},"：业务 API（薄控制器）",{"type":27,"tag":65,"props":1243,"children":1244},{},[1245,1251],{"type":27,"tag":279,"props":1246,"children":1248},{"className":1247},[],[1249],{"type":33,"value":1250},"server/services/",{"type":33,"value":1252},"：领域服务（可复用）",{"type":27,"tag":65,"props":1254,"children":1255},{},[1256,1262],{"type":27,"tag":279,"props":1257,"children":1259},{"className":1258},[],[1260],{"type":33,"value":1261},"server/repositories/",{"type":33,"value":1263},"：数据访问层",{"type":27,"tag":65,"props":1265,"children":1266},{},[1267,1273],{"type":27,"tag":279,"props":1268,"children":1270},{"className":1269},[],[1271],{"type":33,"value":1272},"server/utils/",{"type":33,"value":1274},"：纯工具",{"type":27,"tag":35,"props":1276,"children":1277},{},[1278],{"type":33,"value":1279},"目标是：",{"type":27,"tag":61,"props":1281,"children":1282},{},[1283,1288,1293],{"type":27,"tag":65,"props":1284,"children":1285},{},[1286],{"type":33,"value":1287},"handler 只做协议适配",{"type":27,"tag":65,"props":1289,"children":1290},{},[1291],{"type":33,"value":1292},"业务逻辑可复用、可测试",{"type":27,"tag":65,"props":1294,"children":1295},{},[1296],{"type":33,"value":1297},"横切能力集中化",{"type":27,"tag":46,"props":1299,"children":1300},{},[],{"type":27,"tag":28,"props":1302,"children":1304},{"id":1303},"总结",[1305],{"type":33,"value":1303},{"type":27,"tag":35,"props":1307,"children":1308},{},[1309,1311,1316],{"type":33,"value":1310},"Nitro 的本质是：把 Nuxt 的服务端能力变成一个",{"type":27,"tag":421,"props":1312,"children":1313},{},[1314],{"type":33,"value":1315},"可编译、可移植、可观测",{"type":33,"value":1317},"的运行时系统。",{"type":27,"tag":35,"props":1319,"children":1320},{},[1321],{"type":33,"value":1322},"你一旦理解了它的生命周期与边界，就可以更有信心地在 Nuxt 里做：",{"type":27,"tag":61,"props":1324,"children":1325},{},[1326,1331,1336,1341],{"type":27,"tag":65,"props":1327,"children":1328},{},[1329],{"type":33,"value":1330},"性能友好的 API",{"type":27,"tag":65,"props":1332,"children":1333},{},[1334],{"type":33,"value":1335},"可控的缓存",{"type":27,"tag":65,"props":1337,"children":1338},{},[1339],{"type":33,"value":1340},"稳定的鉴权与错误处理",{"type":27,"tag":65,"props":1342,"children":1343},{},[1344],{"type":33,"value":1345},"面向多环境部署的工程架构",{"title":7,"searchDepth":375,"depth":375,"links":1347},[1348,1349,1350,1351,1359,1360,1361,1365,1370,1375,1376,1377],{"id":412,"depth":378,"text":396},{"id":506,"depth":378,"text":509},{"id":567,"depth":378,"text":570},{"id":609,"depth":378,"text":1352,"children":1353},"3. 路由系统：server/api 与 server/routes 的区别",[1354,1356,1358],{"id":632,"depth":375,"text":1355},"3.1 server/api/*",{"id":661,"depth":375,"text":1357},"3.2 server/routes/*",{"id":685,"depth":375,"text":688},{"id":717,"depth":378,"text":720},{"id":780,"depth":378,"text":783},{"id":855,"depth":378,"text":858,"children":1362},[1363,1364],{"id":884,"depth":375,"text":887},{"id":909,"depth":375,"text":912},{"id":957,"depth":378,"text":960,"children":1366},[1367,1368,1369],{"id":1009,"depth":375,"text":1012},{"id":1028,"depth":375,"text":1031},{"id":1047,"depth":375,"text":1050},{"id":1087,"depth":378,"text":1090,"children":1371},[1372,1373,1374],{"id":1093,"depth":375,"text":1096},{"id":1112,"depth":375,"text":1115},{"id":1131,"depth":375,"text":1134},{"id":1153,"depth":378,"text":1156},{"id":1208,"depth":378,"text":1211},{"id":1303,"depth":378,"text":1303},"content:topics:nuxt:nitro-engine-deep-dive.md","topics/nuxt/nitro-engine-deep-dive.md","topics/nuxt/nitro-engine-deep-dive",{"_path":1382,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":1383,"description":1384,"date":398,"topic":5,"author":11,"tags":1385,"image":1389,"featured":406,"readingTime":1390,"body":1391,"_type":387,"_id":2162,"_source":389,"_file":2163,"_stem":2164,"_extension":392},"/topics/nuxt/nuxt-rendering-modes-guide","Nuxt 渲染模式选择指南","从 SEO、性能、成本与一致性出发，系统对比 Nuxt 的 CSR/SSR/SSG/ISR（与预渲染）等模式，给出可执行的选型矩阵与落地架构建议。",[13,401,1386,1387,1388],"SSG","ISR","SEO","/images/topics/nuxt/rendering-modes.jpg",22,{"type":24,"children":1392,"toc":2145},[1393,1398,1403,1408,1436,1448,1451,1457,1462,1485,1490,1493,1499,1505,1510,1528,1533,1552,1558,1562,1575,1579,1592,1598,1602,1615,1619,1632,1638,1643,1656,1660,1673,1677,1690,1696,1700,1713,1717,1730,1733,1739,1744,1911,1914,1920,1925,1943,1948,1961,1964,1970,1975,1980,2003,2008,2026,2029,2035,2053,2056,2062,2115,2118,2122,2127],{"type":27,"tag":28,"props":1394,"children":1396},{"id":1395},"nuxt-渲染模式选择指南",[1397],{"type":33,"value":1383},{"type":27,"tag":35,"props":1399,"children":1400},{},[1401],{"type":33,"value":1402},"“到底要不要 SSR？”是 Nuxt 项目里最常见、也最容易吵起来的问题。",{"type":27,"tag":35,"props":1404,"children":1405},{},[1406],{"type":33,"value":1407},"原因是：渲染模式不是一个单点选择，它同时牵动：",{"type":27,"tag":61,"props":1409,"children":1410},{},[1411,1416,1421,1426,1431],{"type":27,"tag":65,"props":1412,"children":1413},{},[1414],{"type":33,"value":1415},"SEO（可索引内容是否直出）",{"type":27,"tag":65,"props":1417,"children":1418},{},[1419],{"type":33,"value":1420},"性能（TTFB/LCP/INP）",{"type":27,"tag":65,"props":1422,"children":1423},{},[1424],{"type":33,"value":1425},"成本（回源、算力、带宽）",{"type":27,"tag":65,"props":1427,"children":1428},{},[1429],{"type":33,"value":1430},"一致性（内容更新策略、缓存失效）",{"type":27,"tag":65,"props":1432,"children":1433},{},[1434],{"type":33,"value":1435},"工程复杂度（部署、观测、回滚）",{"type":27,"tag":35,"props":1437,"children":1438},{},[1439,1441,1446],{"type":33,"value":1440},"这篇文章给你一套",{"type":27,"tag":421,"props":1442,"children":1443},{},[1444],{"type":33,"value":1445},"可执行的选型方法",{"type":33,"value":1447},"：先定义目标，再选模式，最后给落地结构与检查清单。",{"type":27,"tag":46,"props":1449,"children":1450},{},[],{"type":27,"tag":28,"props":1452,"children":1454},{"id":1453},"_1-四个维度决定你的模式",[1455],{"type":33,"value":1456},"1. 四个维度，决定你的模式",{"type":27,"tag":35,"props":1458,"children":1459},{},[1460],{"type":33,"value":1461},"在做任何选择前，先回答四个问题：",{"type":27,"tag":516,"props":1463,"children":1464},{},[1465,1470,1475,1480],{"type":27,"tag":65,"props":1466,"children":1467},{},[1468],{"type":33,"value":1469},"页面是否需要 SEO？（搜索引擎是否必须看到正文）",{"type":27,"tag":65,"props":1471,"children":1472},{},[1473],{"type":33,"value":1474},"数据是否强一致？（用户态/支付/权限）",{"type":27,"tag":65,"props":1476,"children":1477},{},[1478],{"type":33,"value":1479},"更新频率如何？（发布频繁 vs 偶尔）",{"type":27,"tag":65,"props":1481,"children":1482},{},[1483],{"type":33,"value":1484},"流量模型是什么？（突发、平稳、长尾）",{"type":27,"tag":35,"props":1486,"children":1487},{},[1488],{"type":33,"value":1489},"这些问题比“SSR 快还是慢”更重要。",{"type":27,"tag":46,"props":1491,"children":1492},{},[],{"type":27,"tag":28,"props":1494,"children":1496},{"id":1495},"_2-主要模式概览csr-ssr-ssg-isr-预渲染",[1497],{"type":33,"value":1498},"2. 主要模式概览：CSR / SSR / SSG / ISR / 预渲染",{"type":27,"tag":630,"props":1500,"children":1502},{"id":1501},"_21-csr纯客户端渲染",[1503],{"type":33,"value":1504},"2.1 CSR（纯客户端渲染）",{"type":27,"tag":35,"props":1506,"children":1507},{},[1508],{"type":33,"value":1509},"特点：",{"type":27,"tag":61,"props":1511,"children":1512},{},[1513,1518,1523],{"type":27,"tag":65,"props":1514,"children":1515},{},[1516],{"type":33,"value":1517},"HTML 只有壳",{"type":27,"tag":65,"props":1519,"children":1520},{},[1521],{"type":33,"value":1522},"SEO 风险大（除非你不索引）",{"type":27,"tag":65,"props":1524,"children":1525},{},[1526],{"type":33,"value":1527},"首屏性能取决于 JS 与接口",{"type":27,"tag":35,"props":1529,"children":1530},{},[1531],{"type":33,"value":1532},"适用：",{"type":27,"tag":61,"props":1534,"children":1535},{},[1536,1541],{"type":27,"tag":65,"props":1537,"children":1538},{},[1539],{"type":33,"value":1540},"用户中心、后台、强交互工具",{"type":27,"tag":65,"props":1542,"children":1543},{},[1544,1546],{"type":33,"value":1545},"不需要索引或明确 ",{"type":27,"tag":279,"props":1547,"children":1549},{"className":1548},[],[1550],{"type":33,"value":1551},"noindex",{"type":27,"tag":630,"props":1553,"children":1555},{"id":1554},"_22-ssr服务端渲染",[1556],{"type":33,"value":1557},"2.2 SSR（服务端渲染）",{"type":27,"tag":35,"props":1559,"children":1560},{},[1561],{"type":33,"value":1509},{"type":27,"tag":61,"props":1563,"children":1564},{},[1565,1570],{"type":27,"tag":65,"props":1566,"children":1567},{},[1568],{"type":33,"value":1569},"首屏 HTML 直出，SEO 友好",{"type":27,"tag":65,"props":1571,"children":1572},{},[1573],{"type":33,"value":1574},"每次请求可能都需要回源（需要缓存）",{"type":27,"tag":35,"props":1576,"children":1577},{},[1578],{"type":33,"value":1532},{"type":27,"tag":61,"props":1580,"children":1581},{},[1582,1587],{"type":27,"tag":65,"props":1583,"children":1584},{},[1585],{"type":33,"value":1586},"内容需要 SEO，但数据强动态",{"type":27,"tag":65,"props":1588,"children":1589},{},[1590],{"type":33,"value":1591},"你有完善的缓存策略",{"type":27,"tag":630,"props":1593,"children":1595},{"id":1594},"_23-ssg静态生成",[1596],{"type":33,"value":1597},"2.3 SSG（静态生成）",{"type":27,"tag":35,"props":1599,"children":1600},{},[1601],{"type":33,"value":1509},{"type":27,"tag":61,"props":1603,"children":1604},{},[1605,1610],{"type":27,"tag":65,"props":1606,"children":1607},{},[1608],{"type":33,"value":1609},"性能与稳定性最好",{"type":27,"tag":65,"props":1611,"children":1612},{},[1613],{"type":33,"value":1614},"更新成本在“构建时”",{"type":27,"tag":35,"props":1616,"children":1617},{},[1618],{"type":33,"value":1532},{"type":27,"tag":61,"props":1620,"children":1621},{},[1622,1627],{"type":27,"tag":65,"props":1623,"children":1624},{},[1625],{"type":33,"value":1626},"内容站、文档站、营销页",{"type":27,"tag":65,"props":1628,"children":1629},{},[1630],{"type":33,"value":1631},"更新频率不高或可接受构建延迟",{"type":27,"tag":630,"props":1633,"children":1635},{"id":1634},"_24-isr增量静态再生按需生成",[1636],{"type":33,"value":1637},"2.4 ISR（增量静态再生/按需生成）",{"type":27,"tag":35,"props":1639,"children":1640},{},[1641],{"type":33,"value":1642},"在 Nuxt 体系里，ISR 的表达可能来自：",{"type":27,"tag":61,"props":1644,"children":1645},{},[1646,1651],{"type":27,"tag":65,"props":1647,"children":1648},{},[1649],{"type":33,"value":1650},"生成策略 + 缓存策略",{"type":27,"tag":65,"props":1652,"children":1653},{},[1654],{"type":33,"value":1655},"或配合边缘缓存与按需失效",{"type":27,"tag":35,"props":1657,"children":1658},{},[1659],{"type":33,"value":1509},{"type":27,"tag":61,"props":1661,"children":1662},{},[1663,1668],{"type":27,"tag":65,"props":1664,"children":1665},{},[1666],{"type":33,"value":1667},"静态化收益 + 可控更新",{"type":27,"tag":65,"props":1669,"children":1670},{},[1671],{"type":33,"value":1672},"需要你设计“失效与再生成”",{"type":27,"tag":35,"props":1674,"children":1675},{},[1676],{"type":33,"value":1532},{"type":27,"tag":61,"props":1678,"children":1679},{},[1680,1685],{"type":27,"tag":65,"props":1681,"children":1682},{},[1683],{"type":33,"value":1684},"内容更新频繁，但仍要 SEO",{"type":27,"tag":65,"props":1686,"children":1687},{},[1688],{"type":33,"value":1689},"你希望在高峰也保持稳定",{"type":27,"tag":630,"props":1691,"children":1693},{"id":1692},"_25-预渲染prerender",[1694],{"type":33,"value":1695},"2.5 预渲染（prerender）",{"type":27,"tag":35,"props":1697,"children":1698},{},[1699],{"type":33,"value":1509},{"type":27,"tag":61,"props":1701,"children":1702},{},[1703,1708],{"type":27,"tag":65,"props":1704,"children":1705},{},[1706],{"type":33,"value":1707},"对部分路由预先生成 HTML",{"type":27,"tag":65,"props":1709,"children":1710},{},[1711],{"type":33,"value":1712},"适合混合站点",{"type":27,"tag":35,"props":1714,"children":1715},{},[1716],{"type":33,"value":1532},{"type":27,"tag":61,"props":1718,"children":1719},{},[1720,1725],{"type":27,"tag":65,"props":1721,"children":1722},{},[1723],{"type":33,"value":1724},"首页/核心落地页需要 SEO",{"type":27,"tag":65,"props":1726,"children":1727},{},[1728],{"type":33,"value":1729},"工具页/用户页不需要 SEO",{"type":27,"tag":46,"props":1731,"children":1732},{},[],{"type":27,"tag":28,"props":1734,"children":1736},{"id":1735},"_3-选型矩阵可直接用",[1737],{"type":33,"value":1738},"3. 选型矩阵（可直接用）",{"type":27,"tag":35,"props":1740,"children":1741},{},[1742],{"type":33,"value":1743},"你可以按路由维度做选型，而不是全站一刀切。",{"type":27,"tag":1745,"props":1746,"children":1747},"table",{},[1748,1776],{"type":27,"tag":1749,"props":1750,"children":1751},"thead",{},[1752],{"type":27,"tag":1753,"props":1754,"children":1755},"tr",{},[1756,1762,1766,1771],{"type":27,"tag":1757,"props":1758,"children":1759},"th",{},[1760],{"type":33,"value":1761},"页面类型",{"type":27,"tag":1757,"props":1763,"children":1764},{},[1765],{"type":33,"value":1388},{"type":27,"tag":1757,"props":1767,"children":1768},{},[1769],{"type":33,"value":1770},"更新频率",{"type":27,"tag":1757,"props":1772,"children":1773},{},[1774],{"type":33,"value":1775},"推荐",{"type":27,"tag":1777,"props":1778,"children":1779},"tbody",{},[1780,1804,1825,1846,1867,1889],{"type":27,"tag":1753,"props":1781,"children":1782},{},[1783,1789,1794,1799],{"type":27,"tag":1784,"props":1785,"children":1786},"td",{},[1787],{"type":33,"value":1788},"文章详情",{"type":27,"tag":1784,"props":1790,"children":1791},{},[1792],{"type":33,"value":1793},"高",{"type":27,"tag":1784,"props":1795,"children":1796},{},[1797],{"type":33,"value":1798},"中",{"type":27,"tag":1784,"props":1800,"children":1801},{},[1802],{"type":33,"value":1803},"SSG/ISR",{"type":27,"tag":1753,"props":1805,"children":1806},{},[1807,1812,1816,1820],{"type":27,"tag":1784,"props":1808,"children":1809},{},[1810],{"type":33,"value":1811},"文章列表",{"type":27,"tag":1784,"props":1813,"children":1814},{},[1815],{"type":33,"value":1793},{"type":27,"tag":1784,"props":1817,"children":1818},{},[1819],{"type":33,"value":1798},{"type":27,"tag":1784,"props":1821,"children":1822},{},[1823],{"type":33,"value":1824},"SSG/ISR（注意聚合页）",{"type":27,"tag":1753,"props":1826,"children":1827},{},[1828,1833,1837,1841],{"type":27,"tag":1784,"props":1829,"children":1830},{},[1831],{"type":33,"value":1832},"产品详情",{"type":27,"tag":1784,"props":1834,"children":1835},{},[1836],{"type":33,"value":1793},{"type":27,"tag":1784,"props":1838,"children":1839},{},[1840],{"type":33,"value":1793},{"type":27,"tag":1784,"props":1842,"children":1843},{},[1844],{"type":33,"value":1845},"ISR/SSR（配缓存）",{"type":27,"tag":1753,"props":1847,"children":1848},{},[1849,1854,1858,1862],{"type":27,"tag":1784,"props":1850,"children":1851},{},[1852],{"type":33,"value":1853},"搜索结果",{"type":27,"tag":1784,"props":1855,"children":1856},{},[1857],{"type":33,"value":1798},{"type":27,"tag":1784,"props":1859,"children":1860},{},[1861],{"type":33,"value":1793},{"type":27,"tag":1784,"props":1863,"children":1864},{},[1865],{"type":33,"value":1866},"SSR/CSR（配 noindex）",{"type":27,"tag":1753,"props":1868,"children":1869},{},[1870,1875,1880,1884],{"type":27,"tag":1784,"props":1871,"children":1872},{},[1873],{"type":33,"value":1874},"用户中心",{"type":27,"tag":1784,"props":1876,"children":1877},{},[1878],{"type":33,"value":1879},"低",{"type":27,"tag":1784,"props":1881,"children":1882},{},[1883],{"type":33,"value":1793},{"type":27,"tag":1784,"props":1885,"children":1886},{},[1887],{"type":33,"value":1888},"CSR",{"type":27,"tag":1753,"props":1890,"children":1891},{},[1892,1897,1902,1906],{"type":27,"tag":1784,"props":1893,"children":1894},{},[1895],{"type":33,"value":1896},"工具页",{"type":27,"tag":1784,"props":1898,"children":1899},{},[1900],{"type":33,"value":1901},"低/中",{"type":27,"tag":1784,"props":1903,"children":1904},{},[1905],{"type":33,"value":1798},{"type":27,"tag":1784,"props":1907,"children":1908},{},[1909],{"type":33,"value":1910},"CSR + 预渲染核心路由",{"type":27,"tag":46,"props":1912,"children":1913},{},[],{"type":27,"tag":28,"props":1915,"children":1917},{"id":1916},"_4-混合渲染真正的生产最优解",[1918],{"type":33,"value":1919},"4. 混合渲染：真正的生产最优解",{"type":27,"tag":35,"props":1921,"children":1922},{},[1923],{"type":33,"value":1924},"生产上最常见的模式是混合：",{"type":27,"tag":61,"props":1926,"children":1927},{},[1928,1933,1938],{"type":27,"tag":65,"props":1929,"children":1930},{},[1931],{"type":33,"value":1932},"公共内容：静态化（SSG/ISR）+ CDN",{"type":27,"tag":65,"props":1934,"children":1935},{},[1936],{"type":33,"value":1937},"用户态内容：CSR 或 SSR（private/no-store）",{"type":27,"tag":65,"props":1939,"children":1940},{},[1941],{"type":33,"value":1942},"关键落地页：预渲染",{"type":27,"tag":35,"props":1944,"children":1945},{},[1946],{"type":33,"value":1947},"好处：",{"type":27,"tag":61,"props":1949,"children":1950},{},[1951,1956],{"type":27,"tag":65,"props":1952,"children":1953},{},[1954],{"type":33,"value":1955},"SEO 与性能兼得",{"type":27,"tag":65,"props":1957,"children":1958},{},[1959],{"type":33,"value":1960},"成本可控",{"type":27,"tag":46,"props":1962,"children":1963},{},[],{"type":27,"tag":28,"props":1965,"children":1967},{"id":1966},"_5-缓存与失效模式落地的关键",[1968],{"type":33,"value":1969},"5. 缓存与失效：模式落地的关键",{"type":27,"tag":35,"props":1971,"children":1972},{},[1973],{"type":33,"value":1974},"无论你选 SSR 还是 ISR，本质都离不开缓存。",{"type":27,"tag":35,"props":1976,"children":1977},{},[1978],{"type":33,"value":1979},"建议把缓存分层：",{"type":27,"tag":61,"props":1981,"children":1982},{},[1983,1988,1993,1998],{"type":27,"tag":65,"props":1984,"children":1985},{},[1986],{"type":33,"value":1987},"浏览器",{"type":27,"tag":65,"props":1989,"children":1990},{},[1991],{"type":33,"value":1992},"CDN",{"type":27,"tag":65,"props":1994,"children":1995},{},[1996],{"type":33,"value":1997},"应用侧（server runtime）",{"type":27,"tag":65,"props":1999,"children":2000},{},[2001],{"type":33,"value":2002},"数据侧（Redis/DB）",{"type":27,"tag":35,"props":2004,"children":2005},{},[2006],{"type":33,"value":2007},"并给每条路由明确：",{"type":27,"tag":61,"props":2009,"children":2010},{},[2011,2016,2021],{"type":27,"tag":65,"props":2012,"children":2013},{},[2014],{"type":33,"value":2015},"是否 public/private",{"type":27,"tag":65,"props":2017,"children":2018},{},[2019],{"type":33,"value":2020},"TTL 多久",{"type":27,"tag":65,"props":2022,"children":2023},{},[2024],{"type":33,"value":2025},"写操作后如何失效",{"type":27,"tag":46,"props":2027,"children":2028},{},[],{"type":27,"tag":28,"props":2030,"children":2032},{"id":2031},"_6-常见误区",[2033],{"type":33,"value":2034},"6. 常见误区",{"type":27,"tag":61,"props":2036,"children":2037},{},[2038,2043,2048],{"type":27,"tag":65,"props":2039,"children":2040},{},[2041],{"type":33,"value":2042},"“SSR 一定更快”：不一定，TTFB 可能更慢；LCP 受资源与主线程影响更大",{"type":27,"tag":65,"props":2044,"children":2045},{},[2046],{"type":33,"value":2047},"“SSG 一定更好”：构建成本与发布延迟可能无法接受",{"type":27,"tag":65,"props":2049,"children":2050},{},[2051],{"type":33,"value":2052},"“全站一个模式最省事”：短期省事，长期很难优化与扩展",{"type":27,"tag":46,"props":2054,"children":2055},{},[],{"type":27,"tag":28,"props":2057,"children":2059},{"id":2058},"_7-上线检查清单",[2060],{"type":33,"value":2061},"7. 上线检查清单",{"type":27,"tag":61,"props":2063,"children":2066},{"className":2064},[2065],"contains-task-list",[2067,2079,2088,2097,2106],{"type":27,"tag":65,"props":2068,"children":2071},{"className":2069},[2070],"task-list-item",[2072,2077],{"type":27,"tag":2073,"props":2074,"children":2076},"input",{"disabled":406,"type":2075},"checkbox",[],{"type":33,"value":2078}," 按路由明确 SEO 需求（哪些可索引）",{"type":27,"tag":65,"props":2080,"children":2082},{"className":2081},[2070],[2083,2086],{"type":27,"tag":2073,"props":2084,"children":2085},{"disabled":406,"type":2075},[],{"type":33,"value":2087}," 用户态页面是否 private/no-store",{"type":27,"tag":65,"props":2089,"children":2091},{"className":2090},[2070],[2092,2095],{"type":27,"tag":2073,"props":2093,"children":2094},{"disabled":406,"type":2075},[],{"type":33,"value":2096}," 公共内容是否走 CDN 并有合理 TTL",{"type":27,"tag":65,"props":2098,"children":2100},{"className":2099},[2070],[2101,2104],{"type":27,"tag":2073,"props":2102,"children":2103},{"disabled":406,"type":2075},[],{"type":33,"value":2105}," 更新路径是否有失效机制（发布事件）",{"type":27,"tag":65,"props":2107,"children":2109},{"className":2108},[2070],[2110,2113],{"type":27,"tag":2073,"props":2111,"children":2112},{"disabled":406,"type":2075},[],{"type":33,"value":2114}," 是否有 RUM/日志来验证效果",{"type":27,"tag":46,"props":2116,"children":2117},{},[],{"type":27,"tag":28,"props":2119,"children":2120},{"id":1303},[2121],{"type":33,"value":1303},{"type":27,"tag":35,"props":2123,"children":2124},{},[2125],{"type":33,"value":2126},"Nuxt 渲染模式选型的正确做法是：",{"type":27,"tag":61,"props":2128,"children":2129},{},[2130,2135,2140],{"type":27,"tag":65,"props":2131,"children":2132},{},[2133],{"type":33,"value":2134},"以“页面类型”而不是“站点整体”做选择",{"type":27,"tag":65,"props":2136,"children":2137},{},[2138],{"type":33,"value":2139},"把缓存与失效当成一等公民",{"type":27,"tag":65,"props":2141,"children":2142},{},[2143],{"type":33,"value":2144},"用观测验证，而不是凭感觉",{"title":7,"searchDepth":375,"depth":375,"links":2146},[2147,2148,2149,2156,2157,2158,2159,2160,2161],{"id":1395,"depth":378,"text":1383},{"id":1453,"depth":378,"text":1456},{"id":1495,"depth":378,"text":1498,"children":2150},[2151,2152,2153,2154,2155],{"id":1501,"depth":375,"text":1504},{"id":1554,"depth":375,"text":1557},{"id":1594,"depth":375,"text":1597},{"id":1634,"depth":375,"text":1637},{"id":1692,"depth":375,"text":1695},{"id":1735,"depth":378,"text":1738},{"id":1916,"depth":378,"text":1919},{"id":1966,"depth":378,"text":1969},{"id":2031,"depth":378,"text":2034},{"id":2058,"depth":378,"text":2061},{"id":1303,"depth":378,"text":1303},"content:topics:nuxt:nuxt-rendering-modes-guide.md","topics/nuxt/nuxt-rendering-modes-guide.md","topics/nuxt/nuxt-rendering-modes-guide",{"_path":2166,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":2167,"description":2168,"date":2169,"topic":5,"author":11,"tags":2170,"image":2175,"featured":406,"readingTime":2176,"body":2177,"_type":387,"_id":2703,"_source":389,"_file":2704,"_stem":2705,"_extension":392},"/topics/nuxt/nuxt4-major-updates-overview","Nuxt 4 重大更新全面解读：架构升级与开发体验革新","深入解析 Nuxt 4 的重大更新，包括新目录结构、Nitro 2.0 引擎、兼容性层变化、性能优化等核心改进，帮助开发者全面了解新版本特性并做好升级准备。","2026-01-18",[2171,2172,401,2173,2174],"Nuxt 4","Vue","全栈框架","版本升级","/images/topics/nuxt/nuxt4-features-overview.jpg",16,{"type":24,"children":2178,"toc":2664},[2179,2185,2191,2196,2201,2207,2213,2218,2227,2235,2243,2249,2254,2265,2271,2280,2286,2292,2297,2306,2312,2321,2327,2336,2342,2348,2357,2363,2372,2378,2387,2393,2399,2408,2414,2423,2429,2440,2449,2455,2461,2470,2476,2485,2491,2500,2506,2512,2521,2527,2536,2542,2548,2558,2564,2573,2579,2584,2589,2594,2612,2615,2620],{"type":27,"tag":28,"props":2180,"children":2182},{"id":2181},"nuxt-4-重大更新全面解读",[2183],{"type":33,"value":2184},"Nuxt 4 重大更新全面解读",{"type":27,"tag":28,"props":2186,"children":2188},{"id":2187},"引言nuxt-的又一次进化",[2189],{"type":33,"value":2190},"引言：Nuxt 的又一次进化",{"type":27,"tag":35,"props":2192,"children":2193},{},[2194],{"type":33,"value":2195},"Nuxt 4 的发布标志着这个 Vue 生态中最受欢迎的全栈框架又迈入了新阶段。从 Nuxt 2 到 Nuxt 3 是一次彻底重写，而 Nuxt 3 到 Nuxt 4 则是在成熟架构上的精进打磨——更清晰的目录结构、更强大的引擎、更好的开发体验。",{"type":27,"tag":35,"props":2197,"children":2198},{},[2199],{"type":33,"value":2200},"这篇文章将全面解读 Nuxt 4 的核心变化，帮助你理解这些改动背后的设计理念，以及它们将如何影响你的日常开发。",{"type":27,"tag":28,"props":2202,"children":2204},{"id":2203},"第一部分新目录结构",[2205],{"type":33,"value":2206},"第一部分：新目录结构",{"type":27,"tag":630,"props":2208,"children":2210},{"id":2209},"_11-从扁平到分层",[2211],{"type":33,"value":2212},"1.1 从扁平到分层",{"type":27,"tag":35,"props":2214,"children":2215},{},[2216],{"type":33,"value":2217},"Nuxt 4 引入了新的目录结构，将应用代码与配置分离：",{"type":27,"tag":2219,"props":2220,"children":2222},"pre",{"code":2221},"# Nuxt 3 目录结构\nproject/\n├── .nuxt/\n├── app.vue\n├── components/\n├── composables/\n├── layouts/\n├── middleware/\n├── pages/\n├── plugins/\n├── public/\n├── server/\n├── nuxt.config.ts\n└── package.json\n\n# Nuxt 4 新目录结构\nproject/\n├── .nuxt/\n├── app/                  # 应用代码集中在 app/ 目录\n│   ├── app.vue\n│   ├── components/\n│   ├── composables/\n│   ├── layouts/\n│   ├── middleware/\n│   ├── pages/\n│   └── plugins/\n├── public/\n├── server/\n├── nuxt.config.ts\n└── package.json\n",[2223],{"type":27,"tag":279,"props":2224,"children":2225},{"__ignoreMap":7},[2226],{"type":33,"value":2221},{"type":27,"tag":35,"props":2228,"children":2229},{},[2230],{"type":27,"tag":421,"props":2231,"children":2232},{},[2233],{"type":33,"value":2234},"为什么这样设计？",{"type":27,"tag":2219,"props":2236,"children":2238},{"code":2237},"┌────────────────────────────────────────────────────────────┐\n│              新目录结构的设计理念                            │\n├────────────────────────────────────────────────────────────┤\n│                                                            │\n│  1. 关注点分离                                             │\n│     ├── app/ - 客户端/同构代码                             │\n│     ├── server/ - 服务端代码                               │\n│     └── 根目录 - 配置和公共资源                             │\n│                                                            │\n│  2. 更清晰的项目边界                                       │\n│     ├── Monorepo 友好                                      │\n│     ├── 多应用项目更清晰                                   │\n│     └── 与其他框架惯例对齐                                 │\n│                                                            │\n│  3. 未来扩展性                                             │\n│     ├── 为多前端支持做准备                                 │\n│     └── 便于工具链识别和处理                               │\n│                                                            │\n└────────────────────────────────────────────────────────────┘\n",[2239],{"type":27,"tag":279,"props":2240,"children":2241},{"__ignoreMap":7},[2242],{"type":33,"value":2237},{"type":27,"tag":630,"props":2244,"children":2246},{"id":2245},"_12-向后兼容",[2247],{"type":33,"value":2248},"1.2 向后兼容",{"type":27,"tag":35,"props":2250,"children":2251},{},[2252],{"type":33,"value":2253},"Nuxt 4 提供了兼容性选项，允许继续使用旧目录结构：",{"type":27,"tag":2219,"props":2255,"children":2260},{"code":2256,"language":2257,"meta":7,"className":2258},"// nuxt.config.ts\nexport default defineNuxtConfig({\n  future: {\n    compatibilityVersion: 4  // 启用 Nuxt 4 特性\n  },\n  \n  // 如果需要继续使用旧目录结构\n  srcDir: './',  // 而不是 'app/'\n  \n  // 或者自定义目录\n  dir: {\n    app: 'src',\n    pages: 'src/pages',\n    layouts: 'src/layouts'\n  }\n});\n","typescript",[2259],"language-typescript",[2261],{"type":27,"tag":279,"props":2262,"children":2263},{"__ignoreMap":7},[2264],{"type":33,"value":2256},{"type":27,"tag":630,"props":2266,"children":2268},{"id":2267},"_13-appconfigts-变化",[2269],{"type":33,"value":2270},"1.3 app.config.ts 变化",{"type":27,"tag":2219,"props":2272,"children":2275},{"code":2273,"language":2257,"meta":7,"className":2274},"// Nuxt 3: app.config.ts 在项目根目录\n// Nuxt 4: app.config.ts 移入 app/ 目录\n\n// app/app.config.ts\nexport default defineAppConfig({\n  ui: {\n    primary: 'green',\n    gray: 'slate'\n  },\n  \n  // 类型安全的应用配置\n  meta: {\n    name: 'My App',\n    description: 'A Nuxt 4 Application'\n  }\n});\n\n// 使用方式不变\nconst appConfig = useAppConfig();\nconsole.log(appConfig.ui.primary);  // 'green'\n",[2259],[2276],{"type":27,"tag":279,"props":2277,"children":2278},{"__ignoreMap":7},[2279],{"type":33,"value":2273},{"type":27,"tag":28,"props":2281,"children":2283},{"id":2282},"第二部分nitro-20-引擎升级",[2284],{"type":33,"value":2285},"第二部分：Nitro 2.0 引擎升级",{"type":27,"tag":630,"props":2287,"children":2289},{"id":2288},"_21-性能提升",[2290],{"type":33,"value":2291},"2.1 性能提升",{"type":27,"tag":35,"props":2293,"children":2294},{},[2295],{"type":33,"value":2296},"Nitro 2.0 带来了显著的性能改进：",{"type":27,"tag":2219,"props":2298,"children":2301},{"code":2299,"language":2257,"meta":7,"className":2300},"// 冷启动时间优化\n// Nitro 1.x: ~150ms\n// Nitro 2.0: ~80ms (约 47% 提升)\n\n// 内存占用优化\n// 同样的应用，内存占用减少约 20%\n\n// 原因：\n// - 更高效的模块加载\n// - 优化的树摇（tree-shaking）\n// - 减少运行时开销\n",[2259],[2302],{"type":27,"tag":279,"props":2303,"children":2304},{"__ignoreMap":7},[2305],{"type":33,"value":2299},{"type":27,"tag":630,"props":2307,"children":2309},{"id":2308},"_22-新的路由系统",[2310],{"type":33,"value":2311},"2.2 新的路由系统",{"type":27,"tag":2219,"props":2313,"children":2316},{"code":2314,"language":2257,"meta":7,"className":2315},"// server/routes/api/[...slug].ts\n\n// Nitro 2.0 新的路由定义方式\nexport default defineEventHandler({\n  // 路由级别配置\n  config: {\n    // 缓存配置\n    cache: {\n      maxAge: 60,\n      staleMaxAge: 3600,\n      swr: true\n    },\n    \n    // CORS 配置\n    cors: {\n      origin: ['https://example.com'],\n      methods: ['GET', 'POST']\n    }\n  },\n  \n  // 处理函数\n  handler: async (event) => {\n    const slug = event.context.params?.slug;\n    return { data: await fetchData(slug) };\n  }\n});\n\n// 支持中间件链\nexport default defineEventHandler({\n  onRequest: [authMiddleware, rateLimitMiddleware],\n  onBeforeResponse: [logMiddleware],\n  \n  handler: (event) => {\n    return { message: 'Hello' };\n  }\n});\n",[2259],[2317],{"type":27,"tag":279,"props":2318,"children":2319},{"__ignoreMap":7},[2320],{"type":33,"value":2314},{"type":27,"tag":630,"props":2322,"children":2324},{"id":2323},"_23-增强的数据获取",[2325],{"type":33,"value":2326},"2.3 增强的数据获取",{"type":27,"tag":2219,"props":2328,"children":2331},{"code":2329,"language":2257,"meta":7,"className":2330},"// Nitro 2.0 改进的 $fetch\n\n// 自动请求去重\nconst [user, posts] = await Promise.all([\n  $fetch('/api/user/1'),\n  $fetch('/api/user/1')  // 相同请求自动去重\n]);\n\n// 请求拦截器\nexport default defineNuxtPlugin(() => {\n  const { $fetch } = useNuxtApp();\n  \n  // 全局请求配置\n  globalThis.$fetch = $fetch.create({\n    onRequest({ request, options }) {\n      options.headers = {\n        ...options.headers,\n        Authorization: `Bearer ${getToken()}`\n      };\n    },\n    \n    onResponseError({ response }) {\n      if (response.status === 401) {\n        navigateTo('/login');\n      }\n    }\n  });\n});\n",[2259],[2332],{"type":27,"tag":279,"props":2333,"children":2334},{"__ignoreMap":7},[2335],{"type":33,"value":2329},{"type":27,"tag":28,"props":2337,"children":2339},{"id":2338},"第三部分兼容性层变化",[2340],{"type":33,"value":2341},"第三部分：兼容性层变化",{"type":27,"tag":630,"props":2343,"children":2345},{"id":2344},"_31-移除的废弃-api",[2346],{"type":33,"value":2347},"3.1 移除的废弃 API",{"type":27,"tag":2219,"props":2349,"children":2352},{"code":2350,"language":2257,"meta":7,"className":2351},"// Nuxt 4 移除了 Nuxt 3 中标记为废弃的 API\n\n// ❌ 已移除\nimport { defineNuxtRouteMiddleware } from '#app'\n\n// ✅ 使用新的 API\nimport { defineNuxtRouteMiddleware } from 'nuxt/app'\n\n// ❌ 已移除\nconst nuxtApp = useNuxtApp()\nnuxtApp.$router  // 不再有 $ 前缀\n\n// ✅ 使用 composables\nconst router = useRouter()\n\n// ❌ 已移除\nuseAsyncData('key', () => fetch(), { lazy: true })\n\n// ✅ 使用 useLazyAsyncData\nuseLazyAsyncData('key', () => fetch())\n",[2259],[2353],{"type":27,"tag":279,"props":2354,"children":2355},{"__ignoreMap":7},[2356],{"type":33,"value":2350},{"type":27,"tag":630,"props":2358,"children":2360},{"id":2359},"_32-类型系统改进",[2361],{"type":33,"value":2362},"3.2 类型系统改进",{"type":27,"tag":2219,"props":2364,"children":2367},{"code":2365,"language":2257,"meta":7,"className":2366},"// Nuxt 4 增强的类型推导\n\n// 页面元数据类型\n// pages/dashboard.vue\n\u003Cscript setup lang=\"ts\">\ndefinePageMeta({\n  // 类型自动推导，IDE 自动补全\n  layout: 'admin',  // 只能填已定义的布局\n  middleware: ['auth'],  // 只能填已定义的中间件\n  \n  // 自定义元数据\n  title: '仪表盘',\n  requiresAuth: true\n});\n\u003C/script>\n\n// 路由参数类型\n// pages/users/[id].vue\n\u003Cscript setup lang=\"ts\">\nconst route = useRoute('users-id');\n//             ^? RouteLocationNormalized\u003C'users-id'>\n\nroute.params.id  // 类型: string\n\u003C/script>\n\n// 运行时配置类型\n// nuxt.config.ts\nexport default defineNuxtConfig({\n  runtimeConfig: {\n    // 私有配置（仅服务端）\n    apiSecret: '',\n    \n    // 公开配置\n    public: {\n      apiBase: ''\n    }\n  }\n});\n\n// 使用时自动推导类型\nconst config = useRuntimeConfig();\nconfig.apiSecret;  // 服务端可用\nconfig.public.apiBase;  // 客户端可用\n",[2259],[2368],{"type":27,"tag":279,"props":2369,"children":2370},{"__ignoreMap":7},[2371],{"type":33,"value":2365},{"type":27,"tag":630,"props":2373,"children":2375},{"id":2374},"_33-useasyncdata-改进",[2376],{"type":33,"value":2377},"3.3 useAsyncData 改进",{"type":27,"tag":2219,"props":2379,"children":2382},{"code":2380,"language":2257,"meta":7,"className":2381},"// Nuxt 4 中 useAsyncData 的改进\n\n// 改进 1：更好的错误处理\nconst { data, error, status } = await useAsyncData('users', () => $fetch('/api/users'));\n\n// status 新增更多状态\n// 'idle' | 'pending' | 'success' | 'error'\n\n// 改进 2：简化的刷新机制\nconst { refresh, clear } = await useAsyncData('users', () => $fetch('/api/users'));\n\n// 带参数刷新\nawait refresh({ dedupe: true });\n\n// 清除缓存\nclear();\n\n// 改进 3：深度响应式默认关闭\nconst { data } = await useAsyncData('config', () => $fetch('/api/config'), {\n  deep: false  // 默认 false，提升性能\n});\n\n// 需要深度响应式时显式开启\nconst { data } = await useAsyncData('form', () => $fetch('/api/form'), {\n  deep: true\n});\n",[2259],[2383],{"type":27,"tag":279,"props":2384,"children":2385},{"__ignoreMap":7},[2386],{"type":33,"value":2380},{"type":27,"tag":28,"props":2388,"children":2390},{"id":2389},"第四部分开发体验改进",[2391],{"type":33,"value":2392},"第四部分：开发体验改进",{"type":27,"tag":630,"props":2394,"children":2396},{"id":2395},"_41-nuxt-devtools-增强",[2397],{"type":33,"value":2398},"4.1 Nuxt DevTools 增强",{"type":27,"tag":2219,"props":2400,"children":2403},{"code":2401,"language":2257,"meta":7,"className":2402},"// Nuxt 4 内置增强版 DevTools\n\n// 新功能：\n// 1. 组件性能分析\n// - 渲染时间追踪\n// - 不必要渲染检测\n// - 内存使用监控\n\n// 2. 数据流可视化\n// - useAsyncData 调用时序图\n// - 数据缓存状态\n// - 请求去重可视化\n\n// 3. 路由调试\n// - 路由匹配过程\n// - 中间件执行顺序\n// - 导航守卫状态\n\n// 启用高级功能\nexport default defineNuxtConfig({\n  devtools: {\n    enabled: true,\n    \n    // 新选项\n    timeline: {\n      enabled: true  // 启用时间线\n    }\n  }\n});\n",[2259],[2404],{"type":27,"tag":279,"props":2405,"children":2406},{"__ignoreMap":7},[2407],{"type":33,"value":2401},{"type":27,"tag":630,"props":2409,"children":2411},{"id":2410},"_42-热更新优化",[2412],{"type":33,"value":2413},"4.2 热更新优化",{"type":27,"tag":2219,"props":2415,"children":2418},{"code":2416,"language":2257,"meta":7,"className":2417},"// Nuxt 4 大幅改进了热更新体验\n\n// 1. 更快的 HMR\n// - 组件变更：\u003C 100ms\n// - 页面变更：\u003C 200ms\n// - 配置变更：\u003C 1s\n\n// 2. 保持状态的更新\n// composables 更新不再丢失组件状态\nconst count = ref(0);  // 更新文件后，值保持\n\n// 3. 错误恢复\n// 修复语法错误后自动恢复，无需重启\n",[2259],[2419],{"type":27,"tag":279,"props":2420,"children":2421},{"__ignoreMap":7},[2422],{"type":33,"value":2416},{"type":27,"tag":630,"props":2424,"children":2426},{"id":2425},"_43-错误处理增强",[2427],{"type":33,"value":2428},"4.3 错误处理增强",{"type":27,"tag":2219,"props":2430,"children":2435},{"code":2431,"language":2432,"meta":7,"className":2433},"\u003C!-- app/error.vue - 增强的错误页面 -->\n\u003Ctemplate>\n  \u003Cdiv class=\"error-page\">\n    \u003Ch1>{{ error.statusCode }}\u003C/h1>\n    \u003Cp>{{ error.message }}\u003C/p>\n    \n    \u003C!-- Nuxt 4 新增：错误堆栈（开发环境） -->\n    \u003Cpre v-if=\"isDev && error.stack\">{{ error.stack }}\u003C/pre>\n    \n    \u003C!-- 新增：错误上下文 -->\n    \u003Cdetails v-if=\"error.data\">\n      \u003Csummary>详细信息\u003C/summary>\n      \u003Cpre>{{ error.data }}\u003C/pre>\n    \u003C/details>\n    \n    \u003Cbutton @click=\"handleError\">重试\u003C/button>\n  \u003C/div>\n\u003C/template>\n\n\u003Cscript setup lang=\"ts\">\nconst props = defineProps\u003C{\n  error: {\n    statusCode: number\n    message: string\n    stack?: string\n    data?: Record\u003Cstring, unknown>\n  }\n}>();\n\nconst isDev = process.dev;\n\nfunction handleError() {\n  clearError({ redirect: '/' });\n}\n\u003C/script>\n","vue",[2434],"language-vue",[2436],{"type":27,"tag":279,"props":2437,"children":2438},{"__ignoreMap":7},[2439],{"type":33,"value":2431},{"type":27,"tag":2219,"props":2441,"children":2444},{"code":2442,"language":2257,"meta":7,"className":2443},"// server/api/users.ts - 增强的服务端错误\n\nexport default defineEventHandler((event) => {\n  const id = getRouterParam(event, 'id');\n  \n  if (!id) {\n    throw createError({\n      statusCode: 400,\n      message: '缺少用户 ID',\n      \n      // Nuxt 4 新增：结构化错误数据\n      data: {\n        field: 'id',\n        constraint: 'required'\n      }\n    });\n  }\n  \n  // 业务错误\n  throw createError({\n    statusCode: 404,\n    message: '用户不存在',\n    data: {\n      userId: id,\n      suggestion: '请检查用户 ID 是否正确'\n    }\n  });\n});\n",[2259],[2445],{"type":27,"tag":279,"props":2446,"children":2447},{"__ignoreMap":7},[2448],{"type":33,"value":2442},{"type":27,"tag":28,"props":2450,"children":2452},{"id":2451},"第五部分性能优化特性",[2453],{"type":33,"value":2454},"第五部分：性能优化特性",{"type":27,"tag":630,"props":2456,"children":2458},{"id":2457},"_51-更智能的代码分割",[2459],{"type":33,"value":2460},"5.1 更智能的代码分割",{"type":27,"tag":2219,"props":2462,"children":2465},{"code":2463,"language":2257,"meta":7,"className":2464},"// Nuxt 4 的自动代码分割更加智能\n\n// 自动路由分割\n// pages/dashboard/\n//   index.vue      -> chunks/dashboard.js\n//   settings.vue   -> chunks/dashboard-settings.js\n//   analytics.vue  -> chunks/dashboard-analytics.js\n\n// 组件级分割\n// components/\n//   HeavyChart.vue -> chunks/heavy-chart.js (自动延迟加载)\n\n// 手动优化\nexport default defineNuxtConfig({\n  vite: {\n    build: {\n      rollupOptions: {\n        output: {\n          // 自定义分块策略\n          manualChunks: {\n            'vendor-vue': ['vue', 'vue-router', 'pinia'],\n            'vendor-ui': ['element-plus']\n          }\n        }\n      }\n    }\n  }\n});\n",[2259],[2466],{"type":27,"tag":279,"props":2467,"children":2468},{"__ignoreMap":7},[2469],{"type":33,"value":2463},{"type":27,"tag":630,"props":2471,"children":2473},{"id":2472},"_52-图片优化增强",[2474],{"type":33,"value":2475},"5.2 图片优化增强",{"type":27,"tag":2219,"props":2477,"children":2480},{"code":2478,"language":2432,"meta":7,"className":2479},"\u003C!-- Nuxt 4 的 nuxt-img 增强 -->\n\u003Ctemplate>\n  \u003CNuxtImg\n    src=\"/images/hero.jpg\"\n    \n    \u003C!-- 新增：自动格式选择 -->\n    format=\"webp,avif\"\n    \n    \u003C!-- 新增：艺术指导响应式 -->\n    :sources=\"[\n      { media: '(max-width: 640px)', src: '/images/hero-mobile.jpg' },\n      { media: '(max-width: 1024px)', src: '/images/hero-tablet.jpg' }\n    ]\"\n    \n    \u003C!-- 新增：模糊占位符 -->\n    placeholder=\"/images/hero-blur.jpg\"\n    \n    \u003C!-- 新增：性能提示 -->\n    :priority=\"true\"\n    fetchpriority=\"high\"\n  />\n\u003C/template>\n\n\u003Cscript setup>\n// 编程式使用\nconst img = useImage();\n\n// 生成优化后的 URL\nconst optimizedUrl = img('/images/photo.jpg', {\n  width: 800,\n  height: 600,\n  format: 'webp',\n  quality: 80\n});\n\u003C/script>\n",[2434],[2481],{"type":27,"tag":279,"props":2482,"children":2483},{"__ignoreMap":7},[2484],{"type":33,"value":2478},{"type":27,"tag":630,"props":2486,"children":2488},{"id":2487},"_53-服务端渲染优化",[2489],{"type":33,"value":2490},"5.3 服务端渲染优化",{"type":27,"tag":2219,"props":2492,"children":2495},{"code":2493,"language":2257,"meta":7,"className":2494},"// Nuxt 4 SSR 性能优化\n\n// 1. 流式 SSR\n// nuxt.config.ts\nexport default defineNuxtConfig({\n  nitro: {\n    // 启用流式 SSR\n    experimental: {\n      wasm: true\n    }\n  },\n  \n  // 组件流式渲染\n  experimental: {\n    componentIslands: true,  // 组件岛\n    payloadExtraction: true  // Payload 提取\n  }\n});\n\n// 2. 选择性 Hydration\n// pages/article/[id].vue\n\u003Ctemplate>\n  \u003Carticle>\n    \u003C!-- 静态内容，不需要 hydration -->\n    \u003CNuxtIsland name=\"ArticleContent\" :props=\"{ content }\" />\n    \n    \u003C!-- 需要交互的部分 -->\n    \u003CCommentSection :articleId=\"id\" />\n  \u003C/article>\n\u003C/template>\n\n// 3. 预加载优化\n\u003Cscript setup>\n// 智能预加载\nconst { data } = await useAsyncData('article', () => $fetch('/api/article/' + id), {\n  // 预加载相关数据\n  preload: [\n    () => $fetch('/api/comments/' + id),\n    () => $fetch('/api/related/' + id)\n  ]\n});\n\u003C/script>\n",[2259],[2496],{"type":27,"tag":279,"props":2497,"children":2498},{"__ignoreMap":7},[2499],{"type":33,"value":2493},{"type":27,"tag":28,"props":2501,"children":2503},{"id":2502},"第六部分模块生态更新",[2504],{"type":33,"value":2505},"第六部分：模块生态更新",{"type":27,"tag":630,"props":2507,"children":2509},{"id":2508},"_61-官方模块适配",[2510],{"type":33,"value":2511},"6.1 官方模块适配",{"type":27,"tag":2219,"props":2513,"children":2516},{"code":2514,"language":2257,"meta":7,"className":2515},"// 主要官方模块的 Nuxt 4 兼容版本\n\n// @nuxtjs/i18n v9\nexport default defineNuxtConfig({\n  modules: ['@nuxtjs/i18n'],\n  \n  i18n: {\n    // 新增：编译时优化\n    bundle: {\n      optimizeTranslations: true\n    },\n    \n    // 新增：类型生成\n    types: 'composition'\n  }\n});\n\n// @nuxt/content v3\nexport default defineNuxtConfig({\n  modules: ['@nuxt/content'],\n  \n  content: {\n    // 新增：更强的查询 API\n    experimental: {\n      clientDB: true,\n      stripQueryParameters: true\n    }\n  }\n});\n\n// @pinia/nuxt v0.6\nexport default defineNuxtConfig({\n  modules: ['@pinia/nuxt'],\n  \n  pinia: {\n    // 新增：自动导入优化\n    storesDirs: ['./stores/**']\n  }\n});\n",[2259],[2517],{"type":27,"tag":279,"props":2518,"children":2519},{"__ignoreMap":7},[2520],{"type":33,"value":2514},{"type":27,"tag":630,"props":2522,"children":2524},{"id":2523},"_62-创建-nuxt-4-兼容模块",[2525],{"type":33,"value":2526},"6.2 创建 Nuxt 4 兼容模块",{"type":27,"tag":2219,"props":2528,"children":2531},{"code":2529,"language":2257,"meta":7,"className":2530},"// 模块开发的新约定\n\n// my-module/src/module.ts\nimport { defineNuxtModule, createResolver } from '@nuxt/kit'\n\nexport default defineNuxtModule({\n  meta: {\n    name: 'my-module',\n    configKey: 'myModule',\n    \n    // Nuxt 4 要求\n    compatibility: {\n      nuxt: '^4.0.0'\n    }\n  },\n  \n  defaults: {\n    enabled: true\n  },\n  \n  setup(options, nuxt) {\n    const resolver = createResolver(import.meta.url);\n    \n    // 使用新的 hook API\n    nuxt.hook('app:resolve', (app) => {\n      // app 配置\n    });\n    \n    // 添加运行时插件\n    addPlugin(resolver.resolve('./runtime/plugin'));\n    \n    // 添加组件\n    addComponentsDir({\n      path: resolver.resolve('./runtime/components'),\n      prefix: 'MyModule'\n    });\n  }\n});\n",[2259],[2532],{"type":27,"tag":279,"props":2533,"children":2534},{"__ignoreMap":7},[2535],{"type":33,"value":2529},{"type":27,"tag":28,"props":2537,"children":2539},{"id":2538},"第七部分迁移准备",[2540],{"type":33,"value":2541},"第七部分：迁移准备",{"type":27,"tag":630,"props":2543,"children":2545},{"id":2544},"_71-兼容性检查清单",[2546],{"type":33,"value":2547},"7.1 兼容性检查清单",{"type":27,"tag":2219,"props":2549,"children":2553},{"code":2550,"language":387,"meta":7,"className":2551},"## Nuxt 4 迁移检查清单\n\n### 依赖版本\n- [ ] Node.js >= 20\n- [ ] Vue >= 3.4\n- [ ] TypeScript >= 5.3（推荐）\n\n### 代码检查\n- [ ] 移除已废弃的 API 调用\n- [ ] 更新 composables 导入路径\n- [ ] 检查 useAsyncData 用法\n- [ ] 审查中间件语法\n\n### 目录结构\n- [ ] 决定是否采用新目录结构\n- [ ] 移动文件到 app/ 目录（如果采用）\n- [ ] 更新 nuxt.config.ts 配置\n\n### 模块更新\n- [ ] 更新官方模块到兼容版本\n- [ ] 检查第三方模块兼容性\n- [ ] 更新自定义模块\n\n### 测试\n- [ ] 运行全部测试套件\n- [ ] 验证 SSR/SSG 输出\n- [ ] 检查 hydration 错误\n- [ ] 性能基准测试\n",[2552],"language-markdown",[2554],{"type":27,"tag":279,"props":2555,"children":2556},{"__ignoreMap":7},[2557],{"type":33,"value":2550},{"type":27,"tag":630,"props":2559,"children":2561},{"id":2560},"_72-渐进式升级路径",[2562],{"type":33,"value":2563},"7.2 渐进式升级路径",{"type":27,"tag":2219,"props":2565,"children":2568},{"code":2566,"language":2257,"meta":7,"className":2567},"// 使用 compatibilityVersion 实现渐进升级\n\n// 阶段 1：启用 Nuxt 4 特性（保持旧目录结构）\nexport default defineNuxtConfig({\n  future: {\n    compatibilityVersion: 4\n  },\n  srcDir: './'  // 保持旧目录结构\n});\n\n// 阶段 2：迁移到新目录结构\n// 1. 创建 app/ 目录\n// 2. 移动文件\n// 3. 更新导入路径\n\n// 阶段 3：完全升级\nexport default defineNuxtConfig({\n  // 移除 future 配置，默认使用 Nuxt 4 行为\n});\n",[2259],[2569],{"type":27,"tag":279,"props":2570,"children":2571},{"__ignoreMap":7},[2572],{"type":33,"value":2566},{"type":27,"tag":28,"props":2574,"children":2576},{"id":2575},"结语稳步前进的进化",[2577],{"type":33,"value":2578},"结语：稳步前进的进化",{"type":27,"tag":35,"props":2580,"children":2581},{},[2582],{"type":33,"value":2583},"Nuxt 4 不是一次颠覆性的重写，而是在 Nuxt 3 坚实基础上的持续改进。新的目录结构带来更好的组织性，Nitro 2.0 带来更好的性能，增强的类型系统带来更好的开发体验。",{"type":27,"tag":35,"props":2585,"children":2586},{},[2587],{"type":33,"value":2588},"对于 Nuxt 3 用户来说，升级路径相对平滑。核心概念没有变化，熟悉的 API 依然工作。Nuxt 团队显然吸取了 Nuxt 2 到 Nuxt 3 升级的经验，这次提供了更友好的迁移体验。",{"type":27,"tag":35,"props":2590,"children":2591},{},[2592],{"type":33,"value":2593},"如果你正在考虑是否升级，建议：",{"type":27,"tag":61,"props":2595,"children":2596},{},[2597,2602,2607],{"type":27,"tag":65,"props":2598,"children":2599},{},[2600],{"type":33,"value":2601},"新项目直接使用 Nuxt 4",{"type":27,"tag":65,"props":2603,"children":2604},{},[2605],{"type":33,"value":2606},"现有项目评估迁移成本后决定",{"type":27,"tag":65,"props":2608,"children":2609},{},[2610],{"type":33,"value":2611},"关注官方迁移指南的更新",{"type":27,"tag":46,"props":2613,"children":2614},{},[],{"type":27,"tag":28,"props":2616,"children":2618},{"id":2617},"参考资源",[2619],{"type":33,"value":2617},{"type":27,"tag":61,"props":2621,"children":2622},{},[2623,2634,2644,2654],{"type":27,"tag":65,"props":2624,"children":2625},{},[2626],{"type":27,"tag":350,"props":2627,"children":2631},{"href":2628,"rel":2629},"https://nuxt.com/blog/v4",[2630],"nofollow",[2632],{"type":33,"value":2633},"Nuxt 4 官方公告",{"type":27,"tag":65,"props":2635,"children":2636},{},[2637],{"type":27,"tag":350,"props":2638,"children":2641},{"href":2639,"rel":2640},"https://nuxt.com/docs/migration/upgrade",[2630],[2642],{"type":33,"value":2643},"Nuxt 4 迁移指南",{"type":27,"tag":65,"props":2645,"children":2646},{},[2647],{"type":27,"tag":350,"props":2648,"children":2651},{"href":2649,"rel":2650},"https://nitro.unjs.io/changelog",[2630],[2652],{"type":33,"value":2653},"Nitro 2.0 更新日志",{"type":27,"tag":65,"props":2655,"children":2656},{},[2657],{"type":27,"tag":350,"props":2658,"children":2661},{"href":2659,"rel":2660},"https://github.com/nuxt/nuxt/issues",[2630],[2662],{"type":33,"value":2663},"Nuxt 路线图",{"title":7,"searchDepth":375,"depth":375,"links":2665},[2666,2667,2668,2673,2678,2683,2688,2693,2697,2701,2702],{"id":2181,"depth":378,"text":2184},{"id":2187,"depth":378,"text":2190},{"id":2203,"depth":378,"text":2206,"children":2669},[2670,2671,2672],{"id":2209,"depth":375,"text":2212},{"id":2245,"depth":375,"text":2248},{"id":2267,"depth":375,"text":2270},{"id":2282,"depth":378,"text":2285,"children":2674},[2675,2676,2677],{"id":2288,"depth":375,"text":2291},{"id":2308,"depth":375,"text":2311},{"id":2323,"depth":375,"text":2326},{"id":2338,"depth":378,"text":2341,"children":2679},[2680,2681,2682],{"id":2344,"depth":375,"text":2347},{"id":2359,"depth":375,"text":2362},{"id":2374,"depth":375,"text":2377},{"id":2389,"depth":378,"text":2392,"children":2684},[2685,2686,2687],{"id":2395,"depth":375,"text":2398},{"id":2410,"depth":375,"text":2413},{"id":2425,"depth":375,"text":2428},{"id":2451,"depth":378,"text":2454,"children":2689},[2690,2691,2692],{"id":2457,"depth":375,"text":2460},{"id":2472,"depth":375,"text":2475},{"id":2487,"depth":375,"text":2490},{"id":2502,"depth":378,"text":2505,"children":2694},[2695,2696],{"id":2508,"depth":375,"text":2511},{"id":2523,"depth":375,"text":2526},{"id":2538,"depth":378,"text":2541,"children":2698},[2699,2700],{"id":2544,"depth":375,"text":2547},{"id":2560,"depth":375,"text":2563},{"id":2575,"depth":378,"text":2578},{"id":2617,"depth":378,"text":2617},"content:topics:nuxt:nuxt4-major-updates-overview.md","topics/nuxt/nuxt4-major-updates-overview.md","topics/nuxt/nuxt4-major-updates-overview",{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":9,"date":10,"topic":5,"author":11,"tags":2707,"image":18,"imageQuery":19,"pexelsPhotoId":20,"pexelsUrl":21,"featured":6,"readingTime":22,"body":2708,"_type":387,"_id":388,"_source":389,"_file":390,"_stem":391,"_extension":392},[13,14,15,16,17],{"type":24,"children":2709,"toc":2984},[2710,2714,2718,2722,2725,2729,2733,2744,2748,2751,2755,2759,2774,2778,2781,2785,2789,2804,2808,2823,2826,2830,2834,2838,2849,2852,2856,2860,2875,2879,2882,2886,2890,2905,2915,2918,2922,2945,2948,2952,2956,2960],{"type":27,"tag":28,"props":2711,"children":2712},{"id":30},[2713],{"type":33,"value":8},{"type":27,"tag":35,"props":2715,"children":2716},{},[2717],{"type":33,"value":39},{"type":27,"tag":35,"props":2719,"children":2720},{},[2721],{"type":33,"value":44},{"type":27,"tag":46,"props":2723,"children":2724},{},[],{"type":27,"tag":28,"props":2726,"children":2727},{"id":51},[2728],{"type":33,"value":54},{"type":27,"tag":35,"props":2730,"children":2731},{},[2732],{"type":33,"value":59},{"type":27,"tag":61,"props":2734,"children":2735},{},[2736,2740],{"type":27,"tag":65,"props":2737,"children":2738},{},[2739],{"type":33,"value":69},{"type":27,"tag":65,"props":2741,"children":2742},{},[2743],{"type":33,"value":74},{"type":27,"tag":35,"props":2745,"children":2746},{},[2747],{"type":33,"value":79},{"type":27,"tag":46,"props":2749,"children":2750},{},[],{"type":27,"tag":28,"props":2752,"children":2753},{"id":85},[2754],{"type":33,"value":88},{"type":27,"tag":35,"props":2756,"children":2757},{},[2758],{"type":33,"value":93},{"type":27,"tag":61,"props":2760,"children":2761},{},[2762,2766,2770],{"type":27,"tag":65,"props":2763,"children":2764},{},[2765],{"type":33,"value":101},{"type":27,"tag":65,"props":2767,"children":2768},{},[2769],{"type":33,"value":106},{"type":27,"tag":65,"props":2771,"children":2772},{},[2773],{"type":33,"value":111},{"type":27,"tag":35,"props":2775,"children":2776},{},[2777],{"type":33,"value":116},{"type":27,"tag":46,"props":2779,"children":2780},{},[],{"type":27,"tag":28,"props":2782,"children":2783},{"id":122},[2784],{"type":33,"value":125},{"type":27,"tag":35,"props":2786,"children":2787},{},[2788],{"type":33,"value":130},{"type":27,"tag":61,"props":2790,"children":2791},{},[2792,2796,2800],{"type":27,"tag":65,"props":2793,"children":2794},{},[2795],{"type":33,"value":138},{"type":27,"tag":65,"props":2797,"children":2798},{},[2799],{"type":33,"value":143},{"type":27,"tag":65,"props":2801,"children":2802},{},[2803],{"type":33,"value":148},{"type":27,"tag":35,"props":2805,"children":2806},{},[2807],{"type":33,"value":153},{"type":27,"tag":61,"props":2809,"children":2810},{},[2811,2815,2819],{"type":27,"tag":65,"props":2812,"children":2813},{},[2814],{"type":33,"value":161},{"type":27,"tag":65,"props":2816,"children":2817},{},[2818],{"type":33,"value":166},{"type":27,"tag":65,"props":2820,"children":2821},{},[2822],{"type":33,"value":171},{"type":27,"tag":46,"props":2824,"children":2825},{},[],{"type":27,"tag":28,"props":2827,"children":2828},{"id":177},[2829],{"type":33,"value":180},{"type":27,"tag":35,"props":2831,"children":2832},{},[2833],{"type":33,"value":185},{"type":27,"tag":35,"props":2835,"children":2836},{},[2837],{"type":33,"value":190},{"type":27,"tag":61,"props":2839,"children":2840},{},[2841,2845],{"type":27,"tag":65,"props":2842,"children":2843},{},[2844],{"type":33,"value":198},{"type":27,"tag":65,"props":2846,"children":2847},{},[2848],{"type":33,"value":203},{"type":27,"tag":46,"props":2850,"children":2851},{},[],{"type":27,"tag":28,"props":2853,"children":2854},{"id":209},[2855],{"type":33,"value":212},{"type":27,"tag":35,"props":2857,"children":2858},{},[2859],{"type":33,"value":217},{"type":27,"tag":61,"props":2861,"children":2862},{},[2863,2867,2871],{"type":27,"tag":65,"props":2864,"children":2865},{},[2866],{"type":33,"value":225},{"type":27,"tag":65,"props":2868,"children":2869},{},[2870],{"type":33,"value":230},{"type":27,"tag":65,"props":2872,"children":2873},{},[2874],{"type":33,"value":235},{"type":27,"tag":35,"props":2876,"children":2877},{},[2878],{"type":33,"value":240},{"type":27,"tag":46,"props":2880,"children":2881},{},[],{"type":27,"tag":28,"props":2883,"children":2884},{"id":246},[2885],{"type":33,"value":249},{"type":27,"tag":35,"props":2887,"children":2888},{},[2889],{"type":33,"value":254},{"type":27,"tag":61,"props":2891,"children":2892},{},[2893,2897,2901],{"type":27,"tag":65,"props":2894,"children":2895},{},[2896],{"type":33,"value":262},{"type":27,"tag":65,"props":2898,"children":2899},{},[2900],{"type":33,"value":267},{"type":27,"tag":65,"props":2902,"children":2903},{},[2904],{"type":33,"value":272},{"type":27,"tag":35,"props":2906,"children":2907},{},[2908,2909,2914],{"type":33,"value":277},{"type":27,"tag":279,"props":2910,"children":2912},{"className":2911},[],[2913],{"type":33,"value":284},{"type":33,"value":286},{"type":27,"tag":46,"props":2916,"children":2917},{},[],{"type":27,"tag":28,"props":2919,"children":2920},{"id":292},[2921],{"type":33,"value":295},{"type":27,"tag":61,"props":2923,"children":2924},{},[2925,2929,2933,2937,2941],{"type":27,"tag":65,"props":2926,"children":2927},{},[2928],{"type":33,"value":303},{"type":27,"tag":65,"props":2930,"children":2931},{},[2932],{"type":33,"value":308},{"type":27,"tag":65,"props":2934,"children":2935},{},[2936],{"type":33,"value":313},{"type":27,"tag":65,"props":2938,"children":2939},{},[2940],{"type":33,"value":318},{"type":27,"tag":65,"props":2942,"children":2943},{},[2944],{"type":33,"value":323},{"type":27,"tag":46,"props":2946,"children":2947},{},[],{"type":27,"tag":28,"props":2949,"children":2950},{"id":329},[2951],{"type":33,"value":332},{"type":27,"tag":35,"props":2953,"children":2954},{},[2955],{"type":33,"value":337},{"type":27,"tag":35,"props":2957,"children":2958},{},[2959],{"type":33,"value":342},{"type":27,"tag":61,"props":2961,"children":2962},{},[2963,2970,2977],{"type":27,"tag":65,"props":2964,"children":2965},{},[2966],{"type":27,"tag":350,"props":2967,"children":2968},{"href":352},[2969],{"type":33,"value":355},{"type":27,"tag":65,"props":2971,"children":2972},{},[2973],{"type":27,"tag":350,"props":2974,"children":2975},{"href":361},[2976],{"type":33,"value":364},{"type":27,"tag":65,"props":2978,"children":2979},{},[2980],{"type":27,"tag":350,"props":2981,"children":2982},{"href":370},[2983],{"type":33,"value":373},{"title":7,"searchDepth":375,"depth":375,"links":2985},[2986,2987,2988,2989,2990,2991,2992,2993,2994],{"id":30,"depth":378,"text":8},{"id":51,"depth":378,"text":54},{"id":85,"depth":378,"text":88},{"id":122,"depth":378,"text":125},{"id":177,"depth":378,"text":180},{"id":209,"depth":378,"text":212},{"id":246,"depth":378,"text":249},{"id":292,"depth":378,"text":295},{"id":329,"depth":378,"text":332},1775975226378]