Skip to content
nuxt-modulesPublic

About

Storybook integration with Nuxt.

Topics

Resources

Stars

492 stars

Watchers

14 watching

Forks

Repository files navigation

Nuxt Storybook

Nuxt Storybook

Integrate Storybook into your Nuxt application.

Installing

npx nuxi@latest module add storybook
npm install -D storybook@next

Storybook 11 is published under the next tag until its release. The first command adds @nuxtjs/storybook to the modules of your nuxt.config:

export default defineNuxtConfig({
  modules: ['@nuxtjs/storybook'],
})

Then run nuxt dev: Storybook is served by the Nuxt dev server under /_storybook/ (http://localhost:3000/_storybook/ by default).

Read the documentation to set up .storybook/main.ts and write your first stories.

Features

👌 Zero configuration to start

🔌 Served by nuxt dev, on the same host and port as your app

🎨 Devtools tab with the Storybook app

🏭 CSF Factories with typed parameters.nuxt

🧪 Mock auto-imports, components and server endpoints in your stories

📦 Extendable by Nuxt modules

🚀 Supports Nuxt 4 and Nuxt 5 with Storybook 11

Requirements

  • Node.js 22+
  • Nuxt 4.x or Nuxt 5.x
  • Storybook 11.x

Contributing

  1. Install dependencies with pnpm.
  2. Run pnpm dev:prepare to generate stubbed dist directory.
  3. Make your changes.
  4. Run pnpm lint to verify that there are no issues (consider adding tests).
  5. Submit a PR.

License

This repository is licensed under the MIT License. Feel free to use the code and modify it according to your needs.

Contacts :

🔖 Mail: javachakir@gmail.com

💬 Discord: ChakAs3

🐦‍⬛ Twitter: @ChakirQatab

Sponsors

Chromatic

Thanks to Chromatic for providing the visual testing platform that helps us review UI changes and catch visual regressions.

About

Storybook integration with Nuxt.

Topics

Resources

Stars

492 stars

Watchers

14 watching

Forks

Releases

Sponsor this project

Used by

Contributors

Languages