SuperAPI AI 工具集

nextjs-developer

前端与建站

查看项目

更新于 10-16 05:50

技能介绍

用途:面向使用 Next.js 15+ App Router 构建生产级应用的开发场景,提供路由架构、组件模式与性能优化的技能指导。主要能力包括:App Router 架构(Server/Client Components、Layouts、Templates、loading.tsx、error.tsx);数据获取与缓存(默认动态渲染、force-cache 静态生成、next.revalidate 定时再验证、revalidatePath 按需失效);文件路由(动态 [param]、catch-all [...slug]、路由组 (folder)、并行路由 @slot、拦截路由);Server Actions 表单处理、变更与乐观更新;React 19 的 use()、useFormStatus()、useOptimistic();Partial Prerendering、Turbopack、after() 后置任务、useLinkStatus() 与 onNavigate。用法:脚本位于 scripts/ 文件夹,如 ./scripts/dev-server.sh [--port PORT] [--turbo]、./scripts/build-production.sh [--analyze]、./scripts/create-page.sh <page-path> [--layout] [--loading] [--error]、./scripts/setup-testing.sh [--playwright];templates/ 提供页面、组件、API 路由、Server Actions、中间件与测试模板;resources/ 提供架构、数据获取、路由与性能等参考指南。Turbopack 通过 CLI 启用:next dev --turbopack、next build --turbopack。限制:部分 Webpack 加载器/插件可能仍需迁移;PPR 需按路由逐步启用;资料未提供收费、价格与平台信息。