Skip to content

Commit 30cb703

Browse files
authored
chore: add vite-plugin-inspect in playground to make debugging easier (#593)
1 parent d20cc09 commit 30cb703

File tree

5 files changed

+24
-11772
lines changed

5 files changed

+24
-11772
lines changed

playground/.storybook/main.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import type { StorybookConfig } from '@storybook-vue/nuxt'
2+
import Inspect from 'vite-plugin-inspect'
23

34
const config: StorybookConfig = {
45
stories: [
@@ -17,5 +18,11 @@ const config: StorybookConfig = {
1718
docs: {
1819
autodocs: 'tag',
1920
},
21+
viteFinal: (config) => {
22+
// For debugging purposes
23+
// View intermediate state of Vite plugins at http://localhost:6006/__inspect
24+
config.plugins.push(Inspect())
25+
return config
26+
},
2027
}
2128
export default config

playground/README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
# Nuxt 3 Minimal Starter
1+
# Playground
2+
3+
View intermediate state of Vite plugins at `http://localhost:6006/__inspect`.
4+
5+
---
26

37
Look at the [Nuxt 3 documentation](https://nuxt.com/docs/getting-started/introduction) to learn more.
48

playground/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,10 @@
1313
"devDependencies": {
1414
"@nuxt/devtools": "^1.1.5",
1515
"@nuxtjs/storybook": "workspace:*",
16-
"@storybook/addon-links": "^8.0.8",
1716
"@storybook/addon-essentials": "^8.0.8",
1817
"@storybook/addon-interactions": "^8.0.8",
19-
"nuxt": "^3.11.1"
18+
"@storybook/addon-links": "^8.0.8",
19+
"nuxt": "^3.11.1",
20+
"vite-plugin-inspect": "^0.8.4"
2021
}
2122
}

0 commit comments

Comments
 (0)