Nuxt is a free and open-source full-stack web framework built on Vue.js that provides server-side rendering (SSR), static site generation (SSG), hybrid rendering, and an intuitive file-based routing system README.md16-19 It is designed to create type-safe, performant, and production-grade applications with zero-config TypeScript support README.md16-24
The Nuxt repository is a monorepo containing the core framework, build tools, and developer utilities. This page provides a high-level overview of the architecture and ecosystem.
For detailed information about specific subsystems, refer to:
Sources: README.md16-28 packages/nuxt/package.json10-11
The Nuxt repository is managed as a pnpm workspace package.json111 It centralizes several key packages that form the framework ecosystem.
| Package | NPM Name | Purpose | Key Exports |
|---|---|---|---|
packages/nuxt | nuxt | Core framework providing application runtime, modules, and CLI entrypoints. | packages/nuxt/package.json18-36 |
packages/kit | @nuxt/kit | Toolkit for authoring modules and interacting with Nuxt programmatically. | packages/kit/package.json14-17 |
packages/schema | @nuxt/schema | Shared TypeScript types and default configuration schemas. | packages/schema/package.json15-19 |
packages/vite | @nuxt/vite-builder | Vite-based bundler implementation for Nuxt. | packages/vite/package.json14-17 |
packages/webpack | @nuxt/webpack-builder | Webpack 5 bundler implementation for Nuxt. | packages/webpack/package.json17-20 |
packages/rspack | @nuxt/rspack-builder | Rspack bundler implementation for high-performance builds. | packages/rspack/package.json17-20 |
packages/nitro-server | @nuxt/nitro-server | Integration for the Nitro server engine within Nuxt. | packages/nuxt/package.json86 |
packages/ui-templates | @nuxt/ui-templates | Internal UI components for error pages and loading indicators. | packages/ui-templates/package.json2-4 |
For details on how these packages interact, see Monorepo Structure.
Sources: package.json52-57 packages/nuxt/package.json81-138 packages/kit/package.json26-49 packages/vite/package.json31-55 packages/webpack/package.json29-73 packages/rspack/package.json29-71
Nuxt's architecture bridges high-level developer code with low-level build tools and server runtimes. The framework is initialized via createNuxt which sets up the internal Nuxt instance and its lifecycle hooks.
Sources: packages/nuxt/package.json14-36 packages/kit/package.json2-10 packages/schema/package.json9-10 packages/nuxt/package.json59-64
The following diagram maps the server-side rendering pipeline to specific code constructs used during a page request.
Sources: packages/nuxt/package.json97 packages/nuxt/package.json152 test/bundle.test.ts40-53 packages/nuxt/package.json113
Nuxt uses c12 packages/kit/package.json27 for configuration loading and untyped packages/nuxt/package.json135 for schema resolution and type generation.
nuxt.config.ts: The primary configuration entry point.app.config.ts: Reactive configuration available at runtime.@nuxt/schema packages/schema/package.json1-13 to provide IDE completion and validation.For details, see Configuration System.
Nuxt abstracts the complexity of modern bundlers through specific builder packages:
vite package.json103webpack package.json109@rspack/core package.json59For details, see Build System.
Nuxt automates the registration of application entities through internal modules:
vue-router packages/nuxt/package.json138 routes.unimport packages/nuxt/package.json132For details, see Routing and Pages and Component System.
Powered by @nuxt/kit packages/kit/package.json1-10 the module system allows developers to hook into any part of the lifecycle using defineNuxtModule.
For details, see Module System.
| Technology | Version | Purpose |
|---|---|---|
| Vue.js | 3.5.40 | UI Framework pnpm-lock.yaml14 |
| Vite | 6.x | Primary Bundler package.json103 |
| Vitest | 3.x | Unit Testing package.json104 |
| Playwright | 1.61.1 | E2E Testing package.json58 |
| Nitro | 3.x | Server Engine package.json87 |
| TypeScript | 5.x | Static Typing package.json100 |
Sources: package.json45-113 pnpm-lock.yaml7-75
The monorepo uses pnpm package.json111 for package management.
pnpm installpnpm dev:prepare (essential for type generation and internal workspace linking) package.json14pnpm play (starts the playground/ directory in dev mode) package.json22For a full guide, see Getting Started.
pnpm test:fixtures package.json28pnpm test:e2e package.json36pnpm test:bundle package.json33Sources: package.json10-44
The nuxi binary (mapped to bin/nuxt.mjs) is the entry point for all CLI commands like dev, build, and generate packages/nuxt/package.json14-17
Nuxt uses internal aliases to provide a consistent API to the application:
#app: Points to the core Nuxt runtime packages/nuxt/package.json60#unhead/composables: Points to head management runtime packages/nuxt/package.json62#pages/composables: Points to page/routing runtime packages/nuxt/package.json63Sources: packages/nuxt/package.json59-64
Refresh this wiki