create-packer 1.45.15 → 1.45.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/template/docusaurus/package.json +52 -52
- package/template/lib/workspace/package.json +77 -77
- package/template/lib/workspace/packages/ts/package.json +30 -30
- package/template/web-app/react-rsbuild/domain/app/components/app-context.tsx +6 -8
- package/template/web-app/react-rsbuild/domain/app/components/app.tsx +1 -0
- package/template/web-app/react-rsbuild/env.d.ts +21 -27
- package/template/web-app/react-rsbuild/package.json +1 -2
- package/template/web-app/react-rsbuild/pages/home/view.css.ts +7 -0
- package/template/web-app/react-rsbuild/pages/home/view.tsx +3 -2
- package/template/web-app/react-rsbuild/rsbuild.config.ts +1 -15
- package/template/web-app/react-rsbuild/shared/styles/global.ts +5 -5
- package/template/web-app/react-rsbuild/shared/styles/index.ts +1 -1
- package/template/web-app/react-rsbuild/shared/styles/tss.ts +6 -0
- package/template/web-app/react-rsbuild/tsconfig.json +0 -1
- package/template/web-app/react-vite/domain/app/components/app-context.tsx +6 -8
- package/template/web-app/react-vite/domain/app/components/app.tsx +1 -0
- package/template/web-app/react-vite/package.json +1 -2
- package/template/web-app/react-vite/pages/home/view.css.ts +7 -0
- package/template/web-app/react-vite/pages/home/view.tsx +3 -2
- package/template/web-app/react-vite/shared/styles/global.ts +5 -5
- package/template/web-app/react-vite/shared/styles/index.ts +1 -0
- package/template/web-app/react-vite/shared/styles/tss.ts +6 -0
- package/template/web-app/react-vite/tsconfig.json +0 -1
- package/template/web-app/react-vite/vite-env.d.ts +6 -14
- package/template/web-app/react-vite/vite.config.ts +1 -5
- package/template/web-app/vue/package.json +71 -71
- package/template/web-app/vue-rsbuild/package.json +73 -73
- package/template/web-extension/package.json +1 -2
- package/template/web-extension/shared/components/app-context/view.tsx +6 -8
- package/template/web-extension/shared/styles/global.ts +6 -6
- package/template/web-extension/shared/styles/index.ts +1 -0
- package/template/web-extension/shared/styles/tss.ts +6 -0
- package/template/web-extension/tsconfig.json +0 -1
- package/template/web-extension/vite-env.d.ts +6 -14
- package/template/web-extension/wxt.config.ts +1 -8
- package/template/web-app/react-rsbuild/pages/home/view.styled.ts +0 -5
- package/template/web-app/react-rsbuild/shared/types/index.ts +0 -1
- package/template/web-app/react-rsbuild/shared/types/utils.ts +0 -2
- package/template/web-app/react-vite/pages/home/view.styled.ts +0 -5
- package/template/web-app/react-vite/shared/types/index.ts +0 -1
- package/template/web-app/react-vite/shared/types/utils.ts +0 -2
- package/template/web-extension/shared/types/index.ts +0 -1
- package/template/web-extension/shared/types/utils.ts +0 -3
package/package.json
CHANGED
|
@@ -1,52 +1,52 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "docusaurus-test",
|
|
3
|
-
"version": "0.0.0",
|
|
4
|
-
"private": true,
|
|
5
|
-
"scripts": {
|
|
6
|
-
"up:docusaurus": "pnpm up @tsconfig/docusaurus @docusaurus/* -L",
|
|
7
|
-
"docusaurus": "docusaurus",
|
|
8
|
-
"start": "docusaurus start",
|
|
9
|
-
"build": "docusaurus build",
|
|
10
|
-
"swizzle": "docusaurus swizzle",
|
|
11
|
-
"deploy": "docusaurus deploy",
|
|
12
|
-
"clear": "docusaurus clear",
|
|
13
|
-
"serve": "docusaurus serve",
|
|
14
|
-
"write-translations": "docusaurus write-translations",
|
|
15
|
-
"write-heading-ids": "docusaurus write-heading-ids",
|
|
16
|
-
"format": "prettier --write \"./src/**/*.{ts,js,tsx,jsx,json,css,scss,less}\"",
|
|
17
|
-
"typecheck": "tsc"
|
|
18
|
-
},
|
|
19
|
-
"dependencies": {
|
|
20
|
-
"@docusaurus/core": "2.4.1",
|
|
21
|
-
"@docusaurus/preset-classic": "2.4.1",
|
|
22
|
-
"@mdx-js/react": "1.6.22",
|
|
23
|
-
"clsx": "1.2.1",
|
|
24
|
-
"prism-react-renderer": "1.3.5",
|
|
25
|
-
"react": "18.2.0",
|
|
26
|
-
"react-dom": "18.2.0"
|
|
27
|
-
},
|
|
28
|
-
"devDependencies": {
|
|
29
|
-
"@docusaurus/module-type-aliases": "2.4.1",
|
|
30
|
-
"@docusaurus/theme-live-codeblock": "2.4.1",
|
|
31
|
-
"@docusaurus/types": "2.4.1",
|
|
32
|
-
"@easyops-cn/docusaurus-search-local": "^0.36.0",
|
|
33
|
-
"@tsconfig/docusaurus": "1.0.5",
|
|
34
|
-
"prettier": "3.2.5",
|
|
35
|
-
"typescript": "5.8.2"
|
|
36
|
-
},
|
|
37
|
-
"browserslist": {
|
|
38
|
-
"production": [
|
|
39
|
-
">0.5%",
|
|
40
|
-
"not dead",
|
|
41
|
-
"not op_mini all"
|
|
42
|
-
],
|
|
43
|
-
"development": [
|
|
44
|
-
"last 1 chrome version",
|
|
45
|
-
"last 1 firefox version",
|
|
46
|
-
"last 1 safari version"
|
|
47
|
-
]
|
|
48
|
-
},
|
|
49
|
-
"engines": {
|
|
50
|
-
"node": ">=16.14"
|
|
51
|
-
}
|
|
52
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "docusaurus-test",
|
|
3
|
+
"version": "0.0.0",
|
|
4
|
+
"private": true,
|
|
5
|
+
"scripts": {
|
|
6
|
+
"up:docusaurus": "pnpm up @tsconfig/docusaurus @docusaurus/* -L",
|
|
7
|
+
"docusaurus": "docusaurus",
|
|
8
|
+
"start": "docusaurus start",
|
|
9
|
+
"build": "docusaurus build",
|
|
10
|
+
"swizzle": "docusaurus swizzle",
|
|
11
|
+
"deploy": "docusaurus deploy",
|
|
12
|
+
"clear": "docusaurus clear",
|
|
13
|
+
"serve": "docusaurus serve",
|
|
14
|
+
"write-translations": "docusaurus write-translations",
|
|
15
|
+
"write-heading-ids": "docusaurus write-heading-ids",
|
|
16
|
+
"format": "prettier --write \"./src/**/*.{ts,js,tsx,jsx,json,css,scss,less}\"",
|
|
17
|
+
"typecheck": "tsc"
|
|
18
|
+
},
|
|
19
|
+
"dependencies": {
|
|
20
|
+
"@docusaurus/core": "2.4.1",
|
|
21
|
+
"@docusaurus/preset-classic": "2.4.1",
|
|
22
|
+
"@mdx-js/react": "1.6.22",
|
|
23
|
+
"clsx": "1.2.1",
|
|
24
|
+
"prism-react-renderer": "1.3.5",
|
|
25
|
+
"react": "18.2.0",
|
|
26
|
+
"react-dom": "18.2.0"
|
|
27
|
+
},
|
|
28
|
+
"devDependencies": {
|
|
29
|
+
"@docusaurus/module-type-aliases": "2.4.1",
|
|
30
|
+
"@docusaurus/theme-live-codeblock": "2.4.1",
|
|
31
|
+
"@docusaurus/types": "2.4.1",
|
|
32
|
+
"@easyops-cn/docusaurus-search-local": "^0.36.0",
|
|
33
|
+
"@tsconfig/docusaurus": "1.0.5",
|
|
34
|
+
"prettier": "3.2.5",
|
|
35
|
+
"typescript": "5.8.2"
|
|
36
|
+
},
|
|
37
|
+
"browserslist": {
|
|
38
|
+
"production": [
|
|
39
|
+
">0.5%",
|
|
40
|
+
"not dead",
|
|
41
|
+
"not op_mini all"
|
|
42
|
+
],
|
|
43
|
+
"development": [
|
|
44
|
+
"last 1 chrome version",
|
|
45
|
+
"last 1 firefox version",
|
|
46
|
+
"last 1 safari version"
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
"engines": {
|
|
50
|
+
"node": ">=16.14"
|
|
51
|
+
}
|
|
52
|
+
}
|
|
@@ -1,77 +1,77 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "my-lib",
|
|
3
|
-
"version": "1.0.0",
|
|
4
|
-
"description": "",
|
|
5
|
-
"private": true,
|
|
6
|
-
"main": "index.js",
|
|
7
|
-
"scripts": {
|
|
8
|
-
"eslint": "eslint",
|
|
9
|
-
"eslint:fix": "eslint --fix",
|
|
10
|
-
"stylelint": "stylelint packages/**/*.{css,scss,less,ts,tsx}",
|
|
11
|
-
"stylelint:fix": "stylelint packages/**/*.{css,scss,less,ts,tsx} --fix",
|
|
12
|
-
"lint": "pnpm -r run lint && pnpm eslint && pnpm stylelint",
|
|
13
|
-
"lint:fix": "pnpm -r run lint && pnpm eslint:fix && pnpm stylelint:fix",
|
|
14
|
-
"build": "ts-node --project ./tsconfig.node.json ./scripts/build.ts",
|
|
15
|
-
"changeVersion": "pnpm changeset && pnpm changeset version && pnpm run clear:changelog",
|
|
16
|
-
"clear:changelog": "pnpm -r exec rimraf CHANGELOG.md",
|
|
17
|
-
"commit": "git add . && cz",
|
|
18
|
-
"push": "pnpm run commit && git push",
|
|
19
|
-
"login": "npm login --registry https://registry.npmjs.org",
|
|
20
|
-
"clean:dist": "pnpm -r exec rimraf dist",
|
|
21
|
-
"format": "prettier --write \"**/*.{ts,js,tsx,jsx,json,css,scss,less}\"",
|
|
22
|
-
"pub": "pnpm run build && pnpm run changeVersion && pnpm run push && pnpm -r publish --registry https://registry.npmjs.org",
|
|
23
|
-
"storybook": "storybook dev -p 6006",
|
|
24
|
-
"build-storybook": "storybook build",
|
|
25
|
-
"up:storybook": "pnpm up storybook eslint-plugin-storybook @storybook/* -L"
|
|
26
|
-
},
|
|
27
|
-
"keywords": [],
|
|
28
|
-
"author": "kevily",
|
|
29
|
-
"license": "ISC",
|
|
30
|
-
"config": {
|
|
31
|
-
"commitizen": {
|
|
32
|
-
"path": "@commitlint/cz-commitlint"
|
|
33
|
-
}
|
|
34
|
-
},
|
|
35
|
-
"dependencies": {
|
|
36
|
-
"1k-tasks": "4.2.1",
|
|
37
|
-
"@commitlint/config-conventional": "17.6.6",
|
|
38
|
-
"@commitlint/cz-commitlint": "17.5.0",
|
|
39
|
-
"@eslint/js": "9.15.0",
|
|
40
|
-
"commitizen": "4.3.0",
|
|
41
|
-
"rimraf": "5.0.1"
|
|
42
|
-
},
|
|
43
|
-
"devDependencies": {
|
|
44
|
-
"@changesets/cli": "2.26.2",
|
|
45
|
-
"@eslint/js": "9.15.0",
|
|
46
|
-
"@storybook/addon-docs": "9.1.2",
|
|
47
|
-
"@storybook/react-vite": "9.1.2",
|
|
48
|
-
"@svgr/rollup": "8.1.0",
|
|
49
|
-
"@types/node": "20.3.2",
|
|
50
|
-
"@types/react": "18.3.3",
|
|
51
|
-
"@types/react-dom": "18.3.0",
|
|
52
|
-
"autoprefixer": "10.4.14",
|
|
53
|
-
"eslint": "9.17.0",
|
|
54
|
-
"eslint-import-resolver-typescript": "3.7.0",
|
|
55
|
-
"eslint-plugin-import": "2.31.0",
|
|
56
|
-
"eslint-plugin-react": "7.37.2",
|
|
57
|
-
"eslint-plugin-react-hooks": "5.1.0",
|
|
58
|
-
"eslint-plugin-storybook": "9.1.2",
|
|
59
|
-
"globals": "15.12.0",
|
|
60
|
-
"inquirer": "^8.1.2",
|
|
61
|
-
"postcss": "8.4.31",
|
|
62
|
-
"postcss-import": "15.1.0",
|
|
63
|
-
"postcss-nesting": "12.0.0",
|
|
64
|
-
"postcss-scss": "4.0.6",
|
|
65
|
-
"postcss-styled-syntax": "0.6.4",
|
|
66
|
-
"prettier": "3.2.5",
|
|
67
|
-
"prop-types": "15.8.1",
|
|
68
|
-
"react": "18.2.0",
|
|
69
|
-
"react-dom": "18.2.0",
|
|
70
|
-
"storybook": "9.1.2",
|
|
71
|
-
"stylelint": "16.10.0",
|
|
72
|
-
"stylelint-config-standard-scss": "13.0.0",
|
|
73
|
-
"ts-node": "10.9.1",
|
|
74
|
-
"typescript": "5.8.2",
|
|
75
|
-
"typescript-eslint": "8.15.0"
|
|
76
|
-
}
|
|
77
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "my-lib",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "",
|
|
5
|
+
"private": true,
|
|
6
|
+
"main": "index.js",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"eslint": "eslint",
|
|
9
|
+
"eslint:fix": "eslint --fix",
|
|
10
|
+
"stylelint": "stylelint packages/**/*.{css,scss,less,ts,tsx}",
|
|
11
|
+
"stylelint:fix": "stylelint packages/**/*.{css,scss,less,ts,tsx} --fix",
|
|
12
|
+
"lint": "pnpm -r run lint && pnpm eslint && pnpm stylelint",
|
|
13
|
+
"lint:fix": "pnpm -r run lint && pnpm eslint:fix && pnpm stylelint:fix",
|
|
14
|
+
"build": "ts-node --project ./tsconfig.node.json ./scripts/build.ts",
|
|
15
|
+
"changeVersion": "pnpm changeset && pnpm changeset version && pnpm run clear:changelog",
|
|
16
|
+
"clear:changelog": "pnpm -r exec rimraf CHANGELOG.md",
|
|
17
|
+
"commit": "git add . && cz",
|
|
18
|
+
"push": "pnpm run commit && git push",
|
|
19
|
+
"login": "npm login --registry https://registry.npmjs.org",
|
|
20
|
+
"clean:dist": "pnpm -r exec rimraf dist",
|
|
21
|
+
"format": "prettier --write \"**/*.{ts,js,tsx,jsx,json,css,scss,less}\"",
|
|
22
|
+
"pub": "pnpm run build && pnpm run changeVersion && pnpm run push && pnpm -r publish --registry https://registry.npmjs.org",
|
|
23
|
+
"storybook": "storybook dev -p 6006",
|
|
24
|
+
"build-storybook": "storybook build",
|
|
25
|
+
"up:storybook": "pnpm up storybook eslint-plugin-storybook @storybook/* -L"
|
|
26
|
+
},
|
|
27
|
+
"keywords": [],
|
|
28
|
+
"author": "kevily",
|
|
29
|
+
"license": "ISC",
|
|
30
|
+
"config": {
|
|
31
|
+
"commitizen": {
|
|
32
|
+
"path": "@commitlint/cz-commitlint"
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"dependencies": {
|
|
36
|
+
"1k-tasks": "4.2.1",
|
|
37
|
+
"@commitlint/config-conventional": "17.6.6",
|
|
38
|
+
"@commitlint/cz-commitlint": "17.5.0",
|
|
39
|
+
"@eslint/js": "9.15.0",
|
|
40
|
+
"commitizen": "4.3.0",
|
|
41
|
+
"rimraf": "5.0.1"
|
|
42
|
+
},
|
|
43
|
+
"devDependencies": {
|
|
44
|
+
"@changesets/cli": "2.26.2",
|
|
45
|
+
"@eslint/js": "9.15.0",
|
|
46
|
+
"@storybook/addon-docs": "9.1.2",
|
|
47
|
+
"@storybook/react-vite": "9.1.2",
|
|
48
|
+
"@svgr/rollup": "8.1.0",
|
|
49
|
+
"@types/node": "20.3.2",
|
|
50
|
+
"@types/react": "18.3.3",
|
|
51
|
+
"@types/react-dom": "18.3.0",
|
|
52
|
+
"autoprefixer": "10.4.14",
|
|
53
|
+
"eslint": "9.17.0",
|
|
54
|
+
"eslint-import-resolver-typescript": "3.7.0",
|
|
55
|
+
"eslint-plugin-import": "2.31.0",
|
|
56
|
+
"eslint-plugin-react": "7.37.2",
|
|
57
|
+
"eslint-plugin-react-hooks": "5.1.0",
|
|
58
|
+
"eslint-plugin-storybook": "9.1.2",
|
|
59
|
+
"globals": "15.12.0",
|
|
60
|
+
"inquirer": "^8.1.2",
|
|
61
|
+
"postcss": "8.4.31",
|
|
62
|
+
"postcss-import": "15.1.0",
|
|
63
|
+
"postcss-nesting": "12.0.0",
|
|
64
|
+
"postcss-scss": "4.0.6",
|
|
65
|
+
"postcss-styled-syntax": "0.6.4",
|
|
66
|
+
"prettier": "3.2.5",
|
|
67
|
+
"prop-types": "15.8.1",
|
|
68
|
+
"react": "18.2.0",
|
|
69
|
+
"react-dom": "18.2.0",
|
|
70
|
+
"storybook": "9.1.2",
|
|
71
|
+
"stylelint": "16.10.0",
|
|
72
|
+
"stylelint-config-standard-scss": "13.0.0",
|
|
73
|
+
"ts-node": "10.9.1",
|
|
74
|
+
"typescript": "5.8.2",
|
|
75
|
+
"typescript-eslint": "8.15.0"
|
|
76
|
+
}
|
|
77
|
+
}
|
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "ts-lib",
|
|
3
|
-
"version": "1.0.0",
|
|
4
|
-
"description": "",
|
|
5
|
-
"main": "dist/index.js",
|
|
6
|
-
"types": "dist/index.d.ts",
|
|
7
|
-
"sideEffects": false,
|
|
8
|
-
"scripts": {
|
|
9
|
-
"lint": "tsc --noEmit -p tsconfig.lint.json",
|
|
10
|
-
"build": "tsc",
|
|
11
|
-
"test": "vitest",
|
|
12
|
-
"coverage": "vitest run --coverage"
|
|
13
|
-
},
|
|
14
|
-
"files": [
|
|
15
|
-
"dist"
|
|
16
|
-
],
|
|
17
|
-
"license": "ISC",
|
|
18
|
-
"devDependencies": {
|
|
19
|
-
"@vitest/coverage-v8": "3.1.2",
|
|
20
|
-
"eslint": "9.17.0",
|
|
21
|
-
"eslint-import-resolver-typescript": "3.7.0",
|
|
22
|
-
"eslint-plugin-import": "2.31.0",
|
|
23
|
-
"prettier": "3.2.5",
|
|
24
|
-
"stylelint": "16.10.0",
|
|
25
|
-
"stylelint-config-standard-scss": "13.0.0",
|
|
26
|
-
"typescript": "5.8.2",
|
|
27
|
-
"typescript-eslint": "8.15.0",
|
|
28
|
-
"vitest": "3.1.2"
|
|
29
|
-
}
|
|
30
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "ts-lib",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"types": "dist/index.d.ts",
|
|
7
|
+
"sideEffects": false,
|
|
8
|
+
"scripts": {
|
|
9
|
+
"lint": "tsc --noEmit -p tsconfig.lint.json",
|
|
10
|
+
"build": "tsc",
|
|
11
|
+
"test": "vitest",
|
|
12
|
+
"coverage": "vitest run --coverage"
|
|
13
|
+
},
|
|
14
|
+
"files": [
|
|
15
|
+
"dist"
|
|
16
|
+
],
|
|
17
|
+
"license": "ISC",
|
|
18
|
+
"devDependencies": {
|
|
19
|
+
"@vitest/coverage-v8": "3.1.2",
|
|
20
|
+
"eslint": "9.17.0",
|
|
21
|
+
"eslint-import-resolver-typescript": "3.7.0",
|
|
22
|
+
"eslint-plugin-import": "2.31.0",
|
|
23
|
+
"prettier": "3.2.5",
|
|
24
|
+
"stylelint": "16.10.0",
|
|
25
|
+
"stylelint-config-standard-scss": "13.0.0",
|
|
26
|
+
"typescript": "5.8.2",
|
|
27
|
+
"typescript-eslint": "8.15.0",
|
|
28
|
+
"vitest": "3.1.2"
|
|
29
|
+
}
|
|
30
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { FunctionComponent, ReactNode } from 'react'
|
|
2
2
|
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
|
|
3
|
-
import {
|
|
3
|
+
import { GlobalStyles } from 'tss-react'
|
|
4
4
|
import { request } from '@/shared/service'
|
|
5
|
-
import { globalCss
|
|
5
|
+
import { globalCss } from '@/shared/styles'
|
|
6
6
|
|
|
7
7
|
const queryClient = new QueryClient({
|
|
8
8
|
defaultOptions: {
|
|
@@ -21,11 +21,9 @@ export interface propsType {
|
|
|
21
21
|
}
|
|
22
22
|
export const Root: FunctionComponent<propsType> = props => {
|
|
23
23
|
return (
|
|
24
|
-
<
|
|
25
|
-
<
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
</QueryClientProvider>
|
|
29
|
-
</ThemeProvider>
|
|
24
|
+
<QueryClientProvider client={queryClient}>
|
|
25
|
+
<GlobalStyles styles={globalCss} />
|
|
26
|
+
{props.children}
|
|
27
|
+
</QueryClientProvider>
|
|
30
28
|
)
|
|
31
29
|
}
|
|
@@ -1,27 +1,21 @@
|
|
|
1
|
-
/// <reference types="@rsbuild/core/types" />
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
export default ReactComponent
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
declare module '@emotion/react' {
|
|
26
|
-
export interface Theme extends themeType {}
|
|
27
|
-
}
|
|
1
|
+
/// <reference types="@rsbuild/core/types" />
|
|
2
|
+
|
|
3
|
+
declare global {
|
|
4
|
+
interface ImportMetaEnv {
|
|
5
|
+
readonly PUBLIC_BASE_URL: string
|
|
6
|
+
readonly PUBLIC_API_HOST: string
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
interface ImportMeta {
|
|
10
|
+
readonly env: ImportMetaEnv
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
declare module '*.svg' {
|
|
14
|
+
const content: string
|
|
15
|
+
export default content
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
declare module '*.svg?react' {
|
|
19
|
+
const ReactComponent: FunctionComponent<SVGProps<SVGSVGElement>>
|
|
20
|
+
export default ReactComponent
|
|
21
|
+
}
|
|
@@ -20,7 +20,6 @@
|
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
22
|
"@emotion/react": "11.14.0",
|
|
23
|
-
"@emotion/styled": "11.14.1",
|
|
24
23
|
"@tanstack/react-query": "5.51.15",
|
|
25
24
|
"axios": "1.7.9",
|
|
26
25
|
"define-zustand": "3.4.0",
|
|
@@ -31,6 +30,7 @@
|
|
|
31
30
|
"react-dom": "18.3.1",
|
|
32
31
|
"react-router": "7.5.0",
|
|
33
32
|
"react-use": "17.5.0",
|
|
33
|
+
"tss-react": "4.9.19",
|
|
34
34
|
"type-fest": "4.33.0",
|
|
35
35
|
"zustand": "5.0.3"
|
|
36
36
|
},
|
|
@@ -45,7 +45,6 @@
|
|
|
45
45
|
"@rsbuild/plugin-svgr": "1.2.2",
|
|
46
46
|
"@rsbuild/plugin-type-check": "1.2.4",
|
|
47
47
|
"@rsdoctor/rspack-plugin": "1.2.3",
|
|
48
|
-
"@swc/plugin-emotion": "11.1.0",
|
|
49
48
|
"@types/node": "18.16.0",
|
|
50
49
|
"@types/qs": "6.9.7",
|
|
51
50
|
"@types/react": "18.3.3",
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { useHomeData } from '@/shared/service'
|
|
2
|
-
import {
|
|
2
|
+
import { useStyles } from './view.css'
|
|
3
3
|
|
|
4
4
|
export default function Home() {
|
|
5
5
|
const { data } = useHomeData()
|
|
6
|
+
const { classes } = useStyles()
|
|
6
7
|
|
|
7
8
|
console.log('data', data)
|
|
8
9
|
|
|
9
|
-
return <
|
|
10
|
+
return <div className={classes.root}>sdfs</div>
|
|
10
11
|
}
|
|
@@ -41,13 +41,6 @@ export default defineConfig(({ envMode, command }) => {
|
|
|
41
41
|
new StylelintWebpackPlugin(),
|
|
42
42
|
process.env.RSDOCTOR && new RsdoctorRspackPlugin()
|
|
43
43
|
]
|
|
44
|
-
},
|
|
45
|
-
swc: {
|
|
46
|
-
jsc: {
|
|
47
|
-
experimental: {
|
|
48
|
-
plugins: [['@swc/plugin-emotion', {}]]
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
44
|
}
|
|
52
45
|
},
|
|
53
46
|
plugins: [
|
|
@@ -59,14 +52,7 @@ export default defineConfig(({ envMode, command }) => {
|
|
|
59
52
|
}
|
|
60
53
|
}),
|
|
61
54
|
pluginSvgr(),
|
|
62
|
-
pluginReact(
|
|
63
|
-
reactRefreshOptions: {
|
|
64
|
-
exclude: [/\.css\.ts$/]
|
|
65
|
-
},
|
|
66
|
-
swcReactOptions: {
|
|
67
|
-
importSource: '@emotion/react'
|
|
68
|
-
}
|
|
69
|
-
})
|
|
55
|
+
pluginReact()
|
|
70
56
|
],
|
|
71
57
|
performance: {
|
|
72
58
|
removeConsole: command === 'build' ? ['log'] : false,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export * from './global'
|
|
2
|
-
export * from './
|
|
2
|
+
export * from './tss'
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { FunctionComponent, ReactNode } from 'react'
|
|
2
2
|
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
|
|
3
|
-
import {
|
|
3
|
+
import { GlobalStyles } from 'tss-react'
|
|
4
4
|
import { request } from '@/shared/service'
|
|
5
|
-
import { globalCss
|
|
5
|
+
import { globalCss } from '@/shared/styles'
|
|
6
6
|
|
|
7
7
|
const queryClient = new QueryClient({
|
|
8
8
|
defaultOptions: {
|
|
@@ -21,11 +21,9 @@ export interface propsType {
|
|
|
21
21
|
}
|
|
22
22
|
export const Root: FunctionComponent<propsType> = props => {
|
|
23
23
|
return (
|
|
24
|
-
<
|
|
25
|
-
<
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
</QueryClientProvider>
|
|
29
|
-
</ThemeProvider>
|
|
24
|
+
<QueryClientProvider client={queryClient}>
|
|
25
|
+
<GlobalStyles styles={globalCss} />
|
|
26
|
+
{props.children}
|
|
27
|
+
</QueryClientProvider>
|
|
30
28
|
)
|
|
31
29
|
}
|
|
@@ -19,7 +19,6 @@
|
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@emotion/react": "11.14.0",
|
|
22
|
-
"@emotion/styled": "11.14.1",
|
|
23
22
|
"@tanstack/react-query": "5.51.15",
|
|
24
23
|
"axios": "1.7.9",
|
|
25
24
|
"define-zustand": "3.4.0",
|
|
@@ -30,6 +29,7 @@
|
|
|
30
29
|
"react-dom": "18.3.1",
|
|
31
30
|
"react-router": "7.5.0",
|
|
32
31
|
"react-use": "17.5.0",
|
|
32
|
+
"tss-react": "4.9.19",
|
|
33
33
|
"type-fest": "4.33.0",
|
|
34
34
|
"zustand": "5.0.3"
|
|
35
35
|
},
|
|
@@ -37,7 +37,6 @@
|
|
|
37
37
|
"@commitlint/cli": "17.6.1",
|
|
38
38
|
"@commitlint/config-conventional": "17.6.1",
|
|
39
39
|
"@commitlint/cz-commitlint": "17.5.0",
|
|
40
|
-
"@emotion/babel-plugin": "11.13.5",
|
|
41
40
|
"@eslint/js": "9.15.0",
|
|
42
41
|
"@faker-js/faker": "8.4.1",
|
|
43
42
|
"@types/node": "18.16.0",
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { useHomeData } from '@/shared/service'
|
|
2
|
-
import {
|
|
2
|
+
import { useStyles } from './view.css'
|
|
3
3
|
|
|
4
4
|
export default function Home() {
|
|
5
5
|
const { data } = useHomeData()
|
|
6
|
+
const { classes } = useStyles()
|
|
6
7
|
|
|
7
8
|
console.log('data', data)
|
|
8
9
|
|
|
9
|
-
return <
|
|
10
|
+
return <div className={classes.root}>sdfs</div>
|
|
10
11
|
}
|
|
@@ -1,20 +1,12 @@
|
|
|
1
1
|
/// <reference types="vite/client" />
|
|
2
2
|
/// <reference types="vite-plugin-svgr/client" />
|
|
3
|
-
import '@emotion/react'
|
|
4
|
-
import { type themeType } from '@/shared/styles'
|
|
5
3
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
// 更多环境变量...
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
interface ImportMeta {
|
|
14
|
-
readonly env: ImportMetaEnv
|
|
15
|
-
}
|
|
4
|
+
interface ImportMetaEnv {
|
|
5
|
+
readonly VITE_BASE_URL: string
|
|
6
|
+
readonly VITE_API_HOST: string
|
|
7
|
+
// 更多环境变量...
|
|
16
8
|
}
|
|
17
9
|
|
|
18
|
-
|
|
19
|
-
|
|
10
|
+
interface ImportMeta {
|
|
11
|
+
readonly env: ImportMetaEnv
|
|
20
12
|
}
|
|
@@ -20,11 +20,7 @@ export default defineConfig(({ mode }) => {
|
|
|
20
20
|
typescript: true,
|
|
21
21
|
eslint: { useFlatConfig: true, lintCommand: 'eslint', dev: { logLevel: ['error'] } }
|
|
22
22
|
}),
|
|
23
|
-
react(
|
|
24
|
-
babel: {
|
|
25
|
-
plugins: ['@emotion']
|
|
26
|
-
}
|
|
27
|
-
})
|
|
23
|
+
react()
|
|
28
24
|
]
|
|
29
25
|
|
|
30
26
|
if (mode === 'analyse') {
|
|
@@ -1,71 +1,71 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "vue-vite",
|
|
3
|
-
"private": true,
|
|
4
|
-
"version": "0.0.0",
|
|
5
|
-
"type": "module",
|
|
6
|
-
"scripts": {
|
|
7
|
-
"prepare": "husky",
|
|
8
|
-
"dev": "vite",
|
|
9
|
-
"build": "vue-tsc --noEmit && vite build",
|
|
10
|
-
"build:analyse": "tsc --noEmit && vite build --mode analyse",
|
|
11
|
-
"preview": "vite preview",
|
|
12
|
-
"format": "prettier --write \"**/*.{vue,ts,js,tsx,jsx,json,css,scss,less}\"",
|
|
13
|
-
"lint": "vue-tsc --noEmit && eslint --no-error-on-unmatched-pattern && stylelint **/*.{css,scss,less,vue}",
|
|
14
|
-
"lint:fix": "eslint --fix && stylelint **/*.{css,scss,less,vue} --fix",
|
|
15
|
-
"cz": "cz",
|
|
16
|
-
"push": "npm run commit && git push",
|
|
17
|
-
"commit": "git add . && npm run cz",
|
|
18
|
-
"up:vite": "pnpm up vite @vitejs/* vite-plugin-* -L",
|
|
19
|
-
"up:vue": "pnpm up vue vue-router vue-tsc -L"
|
|
20
|
-
},
|
|
21
|
-
"dependencies": {
|
|
22
|
-
"axios": "1.7.9",
|
|
23
|
-
"es-toolkit": "1.39.8",
|
|
24
|
-
"pinia": "3.0.3",
|
|
25
|
-
"tailwindcss": "4.1.4",
|
|
26
|
-
"type-fest": "4.33.0",
|
|
27
|
-
"vue": "3.5.20",
|
|
28
|
-
"vue-router": "4.5.1"
|
|
29
|
-
},
|
|
30
|
-
"devDependencies": {
|
|
31
|
-
"@commitlint/cli": "17.6.1",
|
|
32
|
-
"@commitlint/config-conventional": "17.6.1",
|
|
33
|
-
"@commitlint/cz-commitlint": "17.5.0",
|
|
34
|
-
"@eslint/js": "9.15.0",
|
|
35
|
-
"@faker-js/faker": "8.4.1",
|
|
36
|
-
"@tailwindcss/vite": "4.1.4",
|
|
37
|
-
"@types/mockjs": "1.0.10",
|
|
38
|
-
"@vitejs/plugin-vue": "6.0.1",
|
|
39
|
-
"@vitejs/plugin-vue-jsx": "5.0.1",
|
|
40
|
-
"autoprefixer": "10.4.14",
|
|
41
|
-
"commitizen": "4.3.0",
|
|
42
|
-
"cssnano": "6.0.0",
|
|
43
|
-
"eslint": "9.17.0",
|
|
44
|
-
"eslint-import-resolver-typescript": "3.7.0",
|
|
45
|
-
"eslint-plugin-import": "2.31.0",
|
|
46
|
-
"eslint-plugin-vue": "9.32.0",
|
|
47
|
-
"globals": "15.12.0",
|
|
48
|
-
"husky": "9.1.6",
|
|
49
|
-
"inquirer": "8.1.2",
|
|
50
|
-
"postcss": "8.4.38",
|
|
51
|
-
"postcss-html": "1.8.0",
|
|
52
|
-
"postcss-import": "16.1.0",
|
|
53
|
-
"postcss-nesting": "12.1.1",
|
|
54
|
-
"prettier": "3.2.5",
|
|
55
|
-
"rollup-plugin-visualizer": "5.12.0",
|
|
56
|
-
"stylelint": "16.10.0",
|
|
57
|
-
"stylelint-config-standard-scss": "13.1.0",
|
|
58
|
-
"typescript": "5.8.2",
|
|
59
|
-
"typescript-eslint": "8.15.0",
|
|
60
|
-
"vite": "7.1.3",
|
|
61
|
-
"vite-plugin-checker": "0.10.2",
|
|
62
|
-
"vite-plugin-mock-dev-server": "1.9.3",
|
|
63
|
-
"vite-svg-loader": "5.1.0",
|
|
64
|
-
"vue-tsc": "3.0.6"
|
|
65
|
-
},
|
|
66
|
-
"config": {
|
|
67
|
-
"commitizen": {
|
|
68
|
-
"path": "@commitlint/cz-commitlint"
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "vue-vite",
|
|
3
|
+
"private": true,
|
|
4
|
+
"version": "0.0.0",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"prepare": "husky",
|
|
8
|
+
"dev": "vite",
|
|
9
|
+
"build": "vue-tsc --noEmit && vite build",
|
|
10
|
+
"build:analyse": "tsc --noEmit && vite build --mode analyse",
|
|
11
|
+
"preview": "vite preview",
|
|
12
|
+
"format": "prettier --write \"**/*.{vue,ts,js,tsx,jsx,json,css,scss,less}\"",
|
|
13
|
+
"lint": "vue-tsc --noEmit && eslint --no-error-on-unmatched-pattern && stylelint **/*.{css,scss,less,vue}",
|
|
14
|
+
"lint:fix": "eslint --fix && stylelint **/*.{css,scss,less,vue} --fix",
|
|
15
|
+
"cz": "cz",
|
|
16
|
+
"push": "npm run commit && git push",
|
|
17
|
+
"commit": "git add . && npm run cz",
|
|
18
|
+
"up:vite": "pnpm up vite @vitejs/* vite-plugin-* -L",
|
|
19
|
+
"up:vue": "pnpm up vue vue-router vue-tsc -L"
|
|
20
|
+
},
|
|
21
|
+
"dependencies": {
|
|
22
|
+
"axios": "1.7.9",
|
|
23
|
+
"es-toolkit": "1.39.8",
|
|
24
|
+
"pinia": "3.0.3",
|
|
25
|
+
"tailwindcss": "4.1.4",
|
|
26
|
+
"type-fest": "4.33.0",
|
|
27
|
+
"vue": "3.5.20",
|
|
28
|
+
"vue-router": "4.5.1"
|
|
29
|
+
},
|
|
30
|
+
"devDependencies": {
|
|
31
|
+
"@commitlint/cli": "17.6.1",
|
|
32
|
+
"@commitlint/config-conventional": "17.6.1",
|
|
33
|
+
"@commitlint/cz-commitlint": "17.5.0",
|
|
34
|
+
"@eslint/js": "9.15.0",
|
|
35
|
+
"@faker-js/faker": "8.4.1",
|
|
36
|
+
"@tailwindcss/vite": "4.1.4",
|
|
37
|
+
"@types/mockjs": "1.0.10",
|
|
38
|
+
"@vitejs/plugin-vue": "6.0.1",
|
|
39
|
+
"@vitejs/plugin-vue-jsx": "5.0.1",
|
|
40
|
+
"autoprefixer": "10.4.14",
|
|
41
|
+
"commitizen": "4.3.0",
|
|
42
|
+
"cssnano": "6.0.0",
|
|
43
|
+
"eslint": "9.17.0",
|
|
44
|
+
"eslint-import-resolver-typescript": "3.7.0",
|
|
45
|
+
"eslint-plugin-import": "2.31.0",
|
|
46
|
+
"eslint-plugin-vue": "9.32.0",
|
|
47
|
+
"globals": "15.12.0",
|
|
48
|
+
"husky": "9.1.6",
|
|
49
|
+
"inquirer": "8.1.2",
|
|
50
|
+
"postcss": "8.4.38",
|
|
51
|
+
"postcss-html": "1.8.0",
|
|
52
|
+
"postcss-import": "16.1.0",
|
|
53
|
+
"postcss-nesting": "12.1.1",
|
|
54
|
+
"prettier": "3.2.5",
|
|
55
|
+
"rollup-plugin-visualizer": "5.12.0",
|
|
56
|
+
"stylelint": "16.10.0",
|
|
57
|
+
"stylelint-config-standard-scss": "13.1.0",
|
|
58
|
+
"typescript": "5.8.2",
|
|
59
|
+
"typescript-eslint": "8.15.0",
|
|
60
|
+
"vite": "7.1.3",
|
|
61
|
+
"vite-plugin-checker": "0.10.2",
|
|
62
|
+
"vite-plugin-mock-dev-server": "1.9.3",
|
|
63
|
+
"vite-svg-loader": "5.1.0",
|
|
64
|
+
"vue-tsc": "3.0.6"
|
|
65
|
+
},
|
|
66
|
+
"config": {
|
|
67
|
+
"commitizen": {
|
|
68
|
+
"path": "@commitlint/cz-commitlint"
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
@@ -1,73 +1,73 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "vue-vite",
|
|
3
|
-
"private": true,
|
|
4
|
-
"version": "0.0.0",
|
|
5
|
-
"type": "module",
|
|
6
|
-
"scripts": {
|
|
7
|
-
"prepare": "husky",
|
|
8
|
-
"dev": "rsbuild dev",
|
|
9
|
-
"build": "rsbuild build",
|
|
10
|
-
"build:analyse": "rsbuild build --env-mode analyse",
|
|
11
|
-
"build:rsdoctor": "cross-env RSDOCTOR=true rsbuild build",
|
|
12
|
-
"preview": "rsbuild preview",
|
|
13
|
-
"up:rsbuild": "pnpm up @rsbuild/* -L",
|
|
14
|
-
"format": "prettier --write \"**/*.{vue,ts,js,tsx,jsx,json,css,scss,less}\"",
|
|
15
|
-
"lint": "vue-tsc --noEmit && eslint --no-error-on-unmatched-pattern && stylelint **/*.{css,scss,less}",
|
|
16
|
-
"lint:fix": "eslint --fix && stylelint **/*.{css,scss,less} --fix",
|
|
17
|
-
"cz": "cz",
|
|
18
|
-
"push": "npm run commit && git push",
|
|
19
|
-
"commit": "git add . && npm run cz",
|
|
20
|
-
"up:vite": "pnpm up vite @vitejs/* vite-plugin-* -L"
|
|
21
|
-
},
|
|
22
|
-
"dependencies": {
|
|
23
|
-
"axios": "1.7.9",
|
|
24
|
-
"es-toolkit": "1.39.8",
|
|
25
|
-
"pinia": "3.0.3",
|
|
26
|
-
"tailwindcss": "4.1.4",
|
|
27
|
-
"type-fest": "4.33.0",
|
|
28
|
-
"vue": "3.5.20",
|
|
29
|
-
"vue-router": "4.5.1"
|
|
30
|
-
},
|
|
31
|
-
"devDependencies": {
|
|
32
|
-
"@commitlint/cli": "17.6.1",
|
|
33
|
-
"@commitlint/config-conventional": "17.6.1",
|
|
34
|
-
"@commitlint/cz-commitlint": "17.5.0",
|
|
35
|
-
"@eslint/js": "9.15.0",
|
|
36
|
-
"@faker-js/faker": "8.4.1",
|
|
37
|
-
"@rsbuild/core": "1.5.2",
|
|
38
|
-
"@rsbuild/plugin-eslint": "1.1.2",
|
|
39
|
-
"@rsbuild/plugin-type-check": "1.2.4",
|
|
40
|
-
"@rsbuild/plugin-vue": "1.1.2",
|
|
41
|
-
"@rsdoctor/rspack-plugin": "1.2.3",
|
|
42
|
-
"@tailwindcss/postcss": "4.1.4",
|
|
43
|
-
"@types/mockjs": "1.0.10",
|
|
44
|
-
"autoprefixer": "10.4.14",
|
|
45
|
-
"commitizen": "4.3.0",
|
|
46
|
-
"cross-env": "7.0.3",
|
|
47
|
-
"cssnano": "6.0.0",
|
|
48
|
-
"eslint": "9.17.0",
|
|
49
|
-
"eslint-import-resolver-typescript": "3.7.0",
|
|
50
|
-
"eslint-plugin-import": "2.31.0",
|
|
51
|
-
"eslint-plugin-vue": "9.32.0",
|
|
52
|
-
"globals": "15.12.0",
|
|
53
|
-
"husky": "9.1.6",
|
|
54
|
-
"inquirer": "8.1.2",
|
|
55
|
-
"postcss": "8.4.38",
|
|
56
|
-
"postcss-html": "1.8.0",
|
|
57
|
-
"postcss-import": "16.1.0",
|
|
58
|
-
"postcss-nesting": "12.1.1",
|
|
59
|
-
"prettier": "3.2.5",
|
|
60
|
-
"rollup-plugin-visualizer": "5.12.0",
|
|
61
|
-
"stylelint": "16.10.0",
|
|
62
|
-
"stylelint-config-standard-scss": "13.1.0",
|
|
63
|
-
"stylelint-webpack-plugin": "5.0.0",
|
|
64
|
-
"typescript": "5.8.2",
|
|
65
|
-
"typescript-eslint": "8.15.0",
|
|
66
|
-
"vue-tsc": "3.0.6"
|
|
67
|
-
},
|
|
68
|
-
"config": {
|
|
69
|
-
"commitizen": {
|
|
70
|
-
"path": "@commitlint/cz-commitlint"
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "vue-vite",
|
|
3
|
+
"private": true,
|
|
4
|
+
"version": "0.0.0",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"prepare": "husky",
|
|
8
|
+
"dev": "rsbuild dev",
|
|
9
|
+
"build": "rsbuild build",
|
|
10
|
+
"build:analyse": "rsbuild build --env-mode analyse",
|
|
11
|
+
"build:rsdoctor": "cross-env RSDOCTOR=true rsbuild build",
|
|
12
|
+
"preview": "rsbuild preview",
|
|
13
|
+
"up:rsbuild": "pnpm up @rsbuild/* -L",
|
|
14
|
+
"format": "prettier --write \"**/*.{vue,ts,js,tsx,jsx,json,css,scss,less}\"",
|
|
15
|
+
"lint": "vue-tsc --noEmit && eslint --no-error-on-unmatched-pattern && stylelint **/*.{css,scss,less}",
|
|
16
|
+
"lint:fix": "eslint --fix && stylelint **/*.{css,scss,less} --fix",
|
|
17
|
+
"cz": "cz",
|
|
18
|
+
"push": "npm run commit && git push",
|
|
19
|
+
"commit": "git add . && npm run cz",
|
|
20
|
+
"up:vite": "pnpm up vite @vitejs/* vite-plugin-* -L"
|
|
21
|
+
},
|
|
22
|
+
"dependencies": {
|
|
23
|
+
"axios": "1.7.9",
|
|
24
|
+
"es-toolkit": "1.39.8",
|
|
25
|
+
"pinia": "3.0.3",
|
|
26
|
+
"tailwindcss": "4.1.4",
|
|
27
|
+
"type-fest": "4.33.0",
|
|
28
|
+
"vue": "3.5.20",
|
|
29
|
+
"vue-router": "4.5.1"
|
|
30
|
+
},
|
|
31
|
+
"devDependencies": {
|
|
32
|
+
"@commitlint/cli": "17.6.1",
|
|
33
|
+
"@commitlint/config-conventional": "17.6.1",
|
|
34
|
+
"@commitlint/cz-commitlint": "17.5.0",
|
|
35
|
+
"@eslint/js": "9.15.0",
|
|
36
|
+
"@faker-js/faker": "8.4.1",
|
|
37
|
+
"@rsbuild/core": "1.5.2",
|
|
38
|
+
"@rsbuild/plugin-eslint": "1.1.2",
|
|
39
|
+
"@rsbuild/plugin-type-check": "1.2.4",
|
|
40
|
+
"@rsbuild/plugin-vue": "1.1.2",
|
|
41
|
+
"@rsdoctor/rspack-plugin": "1.2.3",
|
|
42
|
+
"@tailwindcss/postcss": "4.1.4",
|
|
43
|
+
"@types/mockjs": "1.0.10",
|
|
44
|
+
"autoprefixer": "10.4.14",
|
|
45
|
+
"commitizen": "4.3.0",
|
|
46
|
+
"cross-env": "7.0.3",
|
|
47
|
+
"cssnano": "6.0.0",
|
|
48
|
+
"eslint": "9.17.0",
|
|
49
|
+
"eslint-import-resolver-typescript": "3.7.0",
|
|
50
|
+
"eslint-plugin-import": "2.31.0",
|
|
51
|
+
"eslint-plugin-vue": "9.32.0",
|
|
52
|
+
"globals": "15.12.0",
|
|
53
|
+
"husky": "9.1.6",
|
|
54
|
+
"inquirer": "8.1.2",
|
|
55
|
+
"postcss": "8.4.38",
|
|
56
|
+
"postcss-html": "1.8.0",
|
|
57
|
+
"postcss-import": "16.1.0",
|
|
58
|
+
"postcss-nesting": "12.1.1",
|
|
59
|
+
"prettier": "3.2.5",
|
|
60
|
+
"rollup-plugin-visualizer": "5.12.0",
|
|
61
|
+
"stylelint": "16.10.0",
|
|
62
|
+
"stylelint-config-standard-scss": "13.1.0",
|
|
63
|
+
"stylelint-webpack-plugin": "5.0.0",
|
|
64
|
+
"typescript": "5.8.2",
|
|
65
|
+
"typescript-eslint": "8.15.0",
|
|
66
|
+
"vue-tsc": "3.0.6"
|
|
67
|
+
},
|
|
68
|
+
"config": {
|
|
69
|
+
"commitizen": {
|
|
70
|
+
"path": "@commitlint/cz-commitlint"
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
@@ -26,7 +26,6 @@
|
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"@emotion/react": "11.14.0",
|
|
29
|
-
"@emotion/styled": "11.14.1",
|
|
30
29
|
"@tanstack/react-query": "5.51.15",
|
|
31
30
|
"@webext-core/messaging": "2.2.0",
|
|
32
31
|
"axios": "1.7.9",
|
|
@@ -36,6 +35,7 @@
|
|
|
36
35
|
"qs": "6.11.2",
|
|
37
36
|
"react": "18.3.1",
|
|
38
37
|
"react-dom": "18.3.1",
|
|
38
|
+
"tss-react": "4.9.19",
|
|
39
39
|
"type-fest": "4.33.0",
|
|
40
40
|
"zustand": "5.0.3"
|
|
41
41
|
},
|
|
@@ -43,7 +43,6 @@
|
|
|
43
43
|
"@commitlint/cli": "17.6.1",
|
|
44
44
|
"@commitlint/config-conventional": "17.6.1",
|
|
45
45
|
"@commitlint/cz-commitlint": "17.5.0",
|
|
46
|
-
"@emotion/babel-plugin": "11.13.5",
|
|
47
46
|
"@eslint/js": "9.15.0",
|
|
48
47
|
"@types/chrome": "0.0.254",
|
|
49
48
|
"@types/node": "18.16.0",
|
|
@@ -1,18 +1,16 @@
|
|
|
1
1
|
import { FunctionComponent, ReactNode } from 'react'
|
|
2
2
|
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
|
|
3
|
-
import {
|
|
4
|
-
import { createGlobalCss
|
|
3
|
+
import { GlobalStyles } from 'tss-react'
|
|
4
|
+
import { createGlobalCss } from '@/shared/styles'
|
|
5
5
|
|
|
6
6
|
const queryClient = new QueryClient()
|
|
7
7
|
|
|
8
8
|
const AppContext: FunctionComponent<{ children: ReactNode; classNameSpace?: string }> = props => {
|
|
9
9
|
return (
|
|
10
|
-
<
|
|
11
|
-
<
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
</QueryClientProvider>
|
|
15
|
-
</ThemeProvider>
|
|
10
|
+
<QueryClientProvider client={queryClient}>
|
|
11
|
+
<GlobalStyles styles={createGlobalCss(props.classNameSpace)} />
|
|
12
|
+
{props.children}
|
|
13
|
+
</QueryClientProvider>
|
|
16
14
|
)
|
|
17
15
|
}
|
|
18
16
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CSSInterpolation } from 'tss-react'
|
|
2
2
|
|
|
3
|
-
export
|
|
4
|
-
return
|
|
5
|
-
|
|
6
|
-
margin: 0
|
|
3
|
+
export function createGlobalCss(nameSpace?: string): CSSInterpolation {
|
|
4
|
+
return {
|
|
5
|
+
[nameSpace ? `.${nameSpace}` : 'body']: {
|
|
6
|
+
margin: 0
|
|
7
7
|
}
|
|
8
|
-
|
|
8
|
+
}
|
|
9
9
|
}
|
|
@@ -1,20 +1,12 @@
|
|
|
1
1
|
/// <reference types="vite/client" />
|
|
2
2
|
/// <reference types="./.wxt/wxt.d.ts" />
|
|
3
|
-
import '@emotion/react'
|
|
4
|
-
import { type themeType } from '@/shared/styles'
|
|
5
3
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
// 更多环境变量...
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
interface ImportMeta {
|
|
14
|
-
readonly env: ImportMetaEnv
|
|
15
|
-
}
|
|
4
|
+
interface ImportMetaEnv {
|
|
5
|
+
readonly VITE_API_HOST: string
|
|
6
|
+
readonly VITE_APP_ID: string
|
|
7
|
+
// 更多环境变量...
|
|
16
8
|
}
|
|
17
9
|
|
|
18
|
-
|
|
19
|
-
|
|
10
|
+
interface ImportMeta {
|
|
11
|
+
readonly env: ImportMetaEnv
|
|
20
12
|
}
|
|
@@ -29,14 +29,7 @@ export default defineConfig({
|
|
|
29
29
|
runner: { disabled: true },
|
|
30
30
|
imports: { eslintrc: { enabled: 9 } },
|
|
31
31
|
vite: ({ mode }) => ({
|
|
32
|
-
plugins: [
|
|
33
|
-
svgr(),
|
|
34
|
-
react({
|
|
35
|
-
babel: {
|
|
36
|
-
plugins: ['@emotion']
|
|
37
|
-
}
|
|
38
|
-
})
|
|
39
|
-
] as any,
|
|
32
|
+
plugins: [svgr(), react()] as any,
|
|
40
33
|
resolve: {
|
|
41
34
|
alias: {
|
|
42
35
|
'@': __dirname
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './utils'
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './utils'
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './utils'
|