feat: init storybook
This commit is contained in:
parent
a2a9bae0e3
commit
e7b58b27e8
6 changed files with 60896 additions and 80 deletions
4
.gitignore
vendored
4
.gitignore
vendored
|
|
@ -104,3 +104,7 @@ tests/*/screenshots
|
||||||
|
|
||||||
# Tests videos
|
# Tests videos
|
||||||
tests/*/videos
|
tests/*/videos
|
||||||
|
|
||||||
|
# Storybook
|
||||||
|
.nuxt-storybook
|
||||||
|
storybook-static
|
||||||
|
|
|
||||||
7
components/MyButton.stories.js
Normal file
7
components/MyButton.stories.js
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
export default {
|
||||||
|
title: "MyButton",
|
||||||
|
}
|
||||||
|
|
||||||
|
export const MyButton = () => {
|
||||||
|
"<MyButton>Primary Button</MyButton>"
|
||||||
|
}
|
||||||
3
components/MyButton.vue
Normal file
3
components/MyButton.vue
Normal file
|
|
@ -0,0 +1,3 @@
|
||||||
|
<template>
|
||||||
|
<button>Button</button>
|
||||||
|
</template>
|
||||||
|
|
@ -361,11 +361,23 @@ export default {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
// https://github.com/nuxt-community/color-mode-module
|
// Color mode configuration (https://github.com/nuxt-community/color-mode-module)
|
||||||
colorMode: {
|
colorMode: {
|
||||||
classSuffix: "",
|
classSuffix: "",
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// Storybook configuration (https://github.com/nuxt-community/storybook)
|
||||||
|
storybook: {
|
||||||
|
webpackFinal(config, _options) {
|
||||||
|
config.node = {
|
||||||
|
fs: "empty",
|
||||||
|
}
|
||||||
|
|
||||||
|
// extend config here
|
||||||
|
return config
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
// Build Configuration (https://go.nuxtjs.dev/config-build)
|
// Build Configuration (https://go.nuxtjs.dev/config-build)
|
||||||
build: {
|
build: {
|
||||||
transpile: ["three"],
|
transpile: ["three"],
|
||||||
|
|
|
||||||
60940
package-lock.json
generated
60940
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
|
@ -16,7 +16,9 @@
|
||||||
"lintfix": "eslint --ext .ts,.js,.vue --ignore-path .gitignore . --fix",
|
"lintfix": "eslint --ext .ts,.js,.vue --ignore-path .gitignore . --fix",
|
||||||
"test": "jest",
|
"test": "jest",
|
||||||
"prepare": "husky install",
|
"prepare": "husky install",
|
||||||
"pre-commit": "lint-staged"
|
"pre-commit": "lint-staged",
|
||||||
|
"storybook": "nuxt storybook",
|
||||||
|
"storybook:build": "nuxt storybook build"
|
||||||
},
|
},
|
||||||
"lint-staged": {
|
"lint-staged": {
|
||||||
"*.{ts,js,vue}": "eslint",
|
"*.{ts,js,vue}": "eslint",
|
||||||
|
|
@ -76,6 +78,7 @@
|
||||||
"@nuxtjs/google-analytics": "^2.4.0",
|
"@nuxtjs/google-analytics": "^2.4.0",
|
||||||
"@nuxtjs/google-fonts": "^1.3.0",
|
"@nuxtjs/google-fonts": "^1.3.0",
|
||||||
"@nuxtjs/pwa": "^3.3.5",
|
"@nuxtjs/pwa": "^3.3.5",
|
||||||
|
"@nuxtjs/storybook": "^4.1.1",
|
||||||
"@nuxtjs/stylelint-module": "^4.0.0",
|
"@nuxtjs/stylelint-module": "^4.0.0",
|
||||||
"@nuxtjs/svg": "^0.1.12",
|
"@nuxtjs/svg": "^0.1.12",
|
||||||
"@testing-library/jest-dom": "^5.14.1",
|
"@testing-library/jest-dom": "^5.14.1",
|
||||||
|
|
@ -104,5 +107,8 @@
|
||||||
"ts-jest": "^27.0.3",
|
"ts-jest": "^27.0.3",
|
||||||
"vue-jest": "^3.0.7",
|
"vue-jest": "^3.0.7",
|
||||||
"worker-loader": "^3.0.8"
|
"worker-loader": "^3.0.8"
|
||||||
|
},
|
||||||
|
"browser": {
|
||||||
|
"fs": false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue