Skip to main content

Nuxt Modern Template

A Nuxt 4 starter. The base is a lean project with TypeScript and linting; everything else is selected in the CLI during generation.

Setup

Scaffold with my Stack tool:

npx @davidaganov/stack

In the generation wizard — Nuxt Modern Template, then architecture and optional modules.

Why

Nuxt ships a lot out of the box, but day one still means wiring TypeScript, ESLint and Prettier, deciding how to split code, plugging in i18n and/or SEO, and putting pages together. This template is for @davidaganov/stack: the CLI stacks layers in the right order, merges configs, and produces a ready project.

The template repo is not a runnable app — it is layer source for the generator. npm run dev runs in the generated project, not in this repository.

Architecture

One of two layouts is chosen at generation time:

ModeDescription
FlatSingle app/ directory — simpler for small sites and MVPs
LayeredRoot app/ + layers/base + layers/ui — suited to larger sites when domain and UI need a clear split

The layered option is close to how larger Nuxt apps isolate features. More on the idea in “Working with Layers in Nuxt 3”.

What’s inside

Base stack: Nuxt 4, Vue 3, TypeScript, @nuxt/eslint, Prettier, favicon generation script.

Optional modules:

  • Tailwind CSS — styling with @tailwindcss/vite
  • Pinia — state via @pinia/nuxt
  • i18n@nuxtjs/i18n with typed locales and Polyglot Keeper to sync translations
  • SEO@nuxtjs/seo: meta, OG images, sitemap, robots
  • Content@nuxt/content with a sample blog and markdown content
  • Tests — Vitest + @nuxt/test-utils

Generation modes match other Stack templates: recommended (all features + demo), custom (hand-pick modules), or empty (bare minimum).

Requirements: Node.js >= 22.5.

Bottom line

A solid choice for bootstrapping Nuxt 4 without setup from scratch: flat or layered, optional modules — and a predictable project structure instead of a bare nuxi init.