Skip to content

Commit 62ff34f

Browse files
author
jerrywu
committed
feat: storybook8
1 parent d687534 commit 62ff34f

File tree

7 files changed

+55
-59
lines changed

7 files changed

+55
-59
lines changed

.eslintignore

+5-5
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ build/*
33
node_modules/*
44
__tests__
55
setupTests.ts
6-
.eslintrc.js
7-
.stylelintrc.js
8-
babel.config.js
9-
postcss.config.js
10-
commitlint.config.js
6+
.eslintrc.cjs
7+
.stylelintrc.cjs
8+
babel.config.cjs
9+
postcss.config.cjs
10+
commitlint.config.cjs
1111
tsconfig.json
1212
**/*.css
1313
**/*.scss

.husky/pre-commit

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
#!/bin/sh
2-
. "$(dirname "$0")/_/husky.sh"
3-
4-
npx lint-staged --allow-empty
5-
1+
npm run lint
2+
npm run stylelint
3+
npm run typecheck

.vscode/settings.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,10 @@
55
"editor.insertSpaces": true,
66
"editor.codeActionsOnSave": {
77
"source.fixAll.eslint": "explicit",
8-
"source.fixAll.tslint": "explicit",
98
"source.fixAll.stylelint": "explicit"
109
},
1110
"eslint.options": {
12-
"overrideConfigFile": "./.eslintrc.js"
11+
"overrideConfigFile": "./.eslintrc.cjs"
1312
},
1413
"eslint.validate": [
1514
"javascript",

docs/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"docs:serve": "vitepress serve docs"
1010
},
1111
"devDependencies": {
12-
"vitepress": "1.0.0-rc.30",
12+
"vitepress": "1.0.0-rc.45",
1313
"vitepress-plugin-sandpack": "latest"
1414
}
1515
}

package.json

+43-44
Original file line numberDiff line numberDiff line change
@@ -65,86 +65,85 @@
6565
"lint": "eslint --ext .ts,.tsx,.vue ./src",
6666
"tsup-w": "tsup --watch",
6767
"dev-pack": "npm run dev:usepack -w playground",
68-
"prepare": "chmod a+x .husky/* && husky install",
68+
"prepare": "chmod a+x .husky/* && husky",
6969
"prepublishOnly": "npm run build",
70-
"postinstall": "rimraf rf node_modules/@types/react && rimraf rf node_modules/@storybook/types/node_modules/@types/react",
7170
"release": "bumpp --commit --tag --push",
7271
"stylelint": "stylelint \"**/*.{css,less,scss,vue}\"",
7372
"test": "vitest",
7473
"test:ui": "vitest --ui",
7574
"typecheck": "tsc && vue-tsc"
7675
},
7776
"dependencies": {
78-
"@babel/runtime": "^7.23.9",
79-
"core-js": "^3.35.1"
77+
"@babel/runtime": "^7.24.0",
78+
"core-js": "^3.36.0"
8079
},
8180
"devDependencies": {
82-
"@babel/plugin-transform-runtime": "^7.23.9",
81+
"@babel/plugin-transform-runtime": "^7.24.0",
8382
"@babel/plugin-transform-typescript": "^7.23.6",
84-
"@babel/preset-env": "^7.23.9",
83+
"@babel/preset-env": "^7.24.0",
8584
"@babel/preset-typescript": "^7.23.3",
86-
"@commitlint/cli": "^18.6.0",
87-
"@commitlint/config-conventional": "^18.6.0",
85+
"@commitlint/cli": "^19.2.0",
86+
"@commitlint/config-conventional": "^19.1.0",
8887
"@rollup/plugin-babel": "^6.0.4",
89-
"@storybook/addon-essentials": "^7.6.11",
90-
"@storybook/addon-interactions": "^7.6.11",
91-
"@storybook/addon-links": "^7.6.11",
92-
"@storybook/addon-onboarding": "^1.0.11",
93-
"@storybook/blocks": "^7.6.11",
94-
"@storybook/testing-library": "^0.2.2",
95-
"@storybook/vue3": "^7.6.11",
96-
"@storybook/vue3-vite": "^7.6.11",
97-
"@swc/core": "^1.3.107",
98-
"@testing-library/jest-dom": "^6.4.0",
88+
"@storybook/addon-essentials": "^8.0.0",
89+
"@storybook/addon-interactions": "^8.0.0",
90+
"@storybook/addon-links": "^8.0.0",
91+
"@storybook/addon-onboarding": "^8.0.0",
92+
"@storybook/blocks": "^8.0.0",
93+
"@storybook/test": "^8.0.0",
94+
"@storybook/vue3": "^8.0.0",
95+
"@storybook/vue3-vite": "^8.0.0",
96+
"@swc/core": "^1.4.8",
97+
"@testing-library/jest-dom": "^6.4.2",
9998
"@testing-library/user-event": "^14.5.2",
100-
"@testing-library/vue": "^8.0.1",
99+
"@testing-library/vue": "^8.0.2",
101100
"@types/lodash.isequal": "^4.5.8",
102101
"@types/lz-string": "^1.5.0",
103-
"@types/node": "^20.11.13",
104-
"@typescript-eslint/eslint-plugin": "^6.20.0",
105-
"@typescript-eslint/parser": "^6.20.0",
106-
"@vitejs/plugin-vue": "^5.0.3",
102+
"@types/node": "^20.11.27",
103+
"@typescript-eslint/eslint-plugin": "^7.2.0",
104+
"@typescript-eslint/parser": "^7.2.0",
105+
"@vitejs/plugin-vue": "^5.0.4",
107106
"@vitejs/plugin-vue-jsx": "^3.1.0",
108-
"@vitest/ui": "^1.2.2",
107+
"@vitest/ui": "^1.3.1",
109108
"@vue/babel-plugin-jsx": "^1.2.1",
110-
"@vue/eslint-config-typescript": "^12.0.0",
109+
"@vue/eslint-config-typescript": "^13.0.0",
111110
"babel-loader": "^9.1.3",
112111
"browserslist-to-esbuild": "^1.2.0",
113-
"bumpp": "^9.3.0",
112+
"bumpp": "^9.4.0",
114113
"cross-env": "^7.0.3",
115-
"cssnano": "^6.0.3",
114+
"cssnano": "^6.1.0",
116115
"esbuild-plugin-babel": "^0.2.3",
117-
"eslint": "^8.56.0",
116+
"eslint": "^8.57.0",
118117
"eslint-config-airbnb-base": "^15.0.0",
119-
"eslint-config-airbnb-typescript": "^17.1.0",
118+
"eslint-config-airbnb-typescript": "^18.0.0",
120119
"eslint-plugin-import": "^2.29.1",
121120
"eslint-plugin-jsx-a11y": "^6.8.0",
122-
"eslint-plugin-storybook": "^0.6.15",
123-
"eslint-plugin-vue": "^9.21.0",
124-
"husky": "^9.0.7",
121+
"eslint-plugin-storybook": "^0.8.0",
122+
"eslint-plugin-vue": "^9.23.0",
123+
"husky": "^9.0.11",
125124
"jsdom": "^24.0.0",
126-
"lint-staged": "^15.2.0",
127-
"npm": "^10.4.0",
125+
"lint-staged": "^15.2.2",
126+
"npm": "^10.5.0",
128127
"npm-run-all": "^4.1.5",
129-
"postcss": "^8.4.33",
128+
"postcss": "^8.4.35",
130129
"postcss-cli": "^11.0.0",
131130
"postcss-flexbugs-fixes": "^5.0.2",
132131
"postcss-nested": "^6.0.1",
133-
"postcss-preset-env": "^9.3.0",
132+
"postcss-preset-env": "^9.5.1",
134133
"postcss-scss": "^4.0.9",
135134
"rimraf": "^5.0.5",
136-
"sass": "^1.70.0",
135+
"sass": "^1.72.0",
137136
"shelljs": "^0.8.5",
138-
"storybook": "^7.6.11",
137+
"storybook": "^8.0.0",
139138
"stylelint": "^15.11.0",
140139
"stylelint-config-recommended-vue": "^1.5.0",
141140
"stylelint-config-standard": "^34.0.0",
142-
"tsup": "^8.0.1",
143-
"typescript": "~5.3.3",
144-
"vite": "^5.0.12",
145-
"vite-plugin-dts": "^3.7.2",
146-
"vitest": "^1.2.2",
147-
"vue-tsc": "^1.8.27"
141+
"tsup": "^8.0.2",
142+
"typescript": "^5.4.2",
143+
"vite": "^5.1.6",
144+
"vite-plugin-dts": "^3.7.3",
145+
"vitest": "^1.3.1",
146+
"vue-tsc": "^2.0.6"
148147
},
149148
"peerDependencies": {
150149
"vue": ">=3.2.0"

playground/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"typecheck": "tsc && vue-tsc"
1111
},
1212
"dependencies": {
13-
"vue-router": "^4.2.5"
13+
"vue-router": "^4.3.0"
1414
},
1515
"devDependencies": {
1616
"cross-env": "^7.0.3",

src/stories/Page.stories.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { Meta, StoryObj } from '@storybook/vue3';
2-
import { within, userEvent } from '@storybook/testing-library';
2+
import { within, userEvent } from '@storybook/test';
33
import MyPage from './Page.vue';
44

55
const meta = {

0 commit comments

Comments
 (0)