create-packer 1.45.11 → 1.45.13
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/web-app/react-rsbuild/.gitignore +5 -0
- package/template/web-app/react-rsbuild/eslint.config.js +1 -1
- package/template/web-app/react-rsbuild/global.css.ts +3 -3
- package/template/web-app/react-rsbuild/main.css +1 -0
- package/template/web-app/react-rsbuild/main.tsx +1 -1
- package/template/web-app/react-rsbuild/package.json +2 -3
- package/template/web-app/react-rsbuild/pages/home/view.css.ts +4 -4
- package/template/web-app/react-rsbuild/pages/home/view.tsx +2 -2
- package/template/web-app/react-rsbuild/panda.config.ts +18 -0
- package/template/web-app/react-rsbuild/postcss.config.cjs +1 -0
- package/template/web-app/react-rsbuild/rsbuild.config.ts +0 -2
- package/template/web-app/react-rsbuild/tsconfig.json +1 -1
- package/template/web-app/react-vite/.gitignore +4 -0
- package/template/web-app/react-vite/eslint.config.js +2 -1
- package/template/web-app/react-vite/global.css.ts +5 -5
- package/template/web-app/react-vite/main.css +1 -0
- package/template/web-app/react-vite/main.tsx +4 -4
- package/template/web-app/react-vite/package.json +2 -3
- package/template/web-app/react-vite/pages/home/view.css.ts +7 -7
- package/template/web-app/react-vite/pages/home/view.tsx +10 -10
- package/template/web-app/react-vite/panda.config.ts +18 -0
- package/template/web-app/react-vite/postcss.config.cjs +1 -0
- package/template/web-app/react-vite/tsconfig.json +1 -1
- package/template/web-app/react-vite/vite.config.ts +63 -79
- package/template/web-app/svelte/package.json +1 -1
- package/template/web-app/vue/package.json +1 -1
- package/template/web-app/vue-rsbuild/package.json +1 -1
- package/template/web-extension/package.json +1 -1
- package/template/web-app/react-rsbuild/shared/styles/index.ts +0 -1
- package/template/web-app/react-rsbuild/shared/styles/theme.css.ts +0 -3
- package/template/web-app/react-vite/.husky/pre-commit +0 -4
- package/template/web-app/react-vite/shared/styles/index.ts +0 -1
- package/template/web-app/react-vite/shared/styles/theme.css.ts +0 -3
package/package.json
CHANGED
|
@@ -10,7 +10,7 @@ const files = scriptExtensions.map(ext => `**/*.${ext}`)
|
|
|
10
10
|
|
|
11
11
|
export default tseslint.config([
|
|
12
12
|
{
|
|
13
|
-
ignores: ['**/node_modules/', '**/dist/', '**/.history/', '**/.vscode/']
|
|
13
|
+
ignores: ['**/node_modules/', '**/dist/', '**/.history/', '**/.vscode/', '**/styled-system/',]
|
|
14
14
|
},
|
|
15
15
|
eslint.configs.recommended,
|
|
16
16
|
importPlugin.flatConfigs.recommended,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@layer reset, base, tokens, recipes, utilities;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"version": "0.0.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
7
|
-
"prepare": "husky
|
|
7
|
+
"prepare": "panda codegen && husky",
|
|
8
8
|
"dev": "rsbuild dev",
|
|
9
9
|
"build": "rsbuild build",
|
|
10
10
|
"build:analyse": "rsbuild build --env-mode analyse",
|
|
@@ -20,7 +20,6 @@
|
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
22
|
"@tanstack/react-query": "5.51.15",
|
|
23
|
-
"@vanilla-extract/css": "1.17.4",
|
|
24
23
|
"axios": "1.7.9",
|
|
25
24
|
"define-zustand": "3.4.0",
|
|
26
25
|
"es-toolkit": "1.39.8",
|
|
@@ -38,6 +37,7 @@
|
|
|
38
37
|
"@commitlint/config-conventional": "17.6.1",
|
|
39
38
|
"@commitlint/cz-commitlint": "17.5.0",
|
|
40
39
|
"@eslint/js": "9.15.0",
|
|
40
|
+
"@pandacss/dev": "1.2.0",
|
|
41
41
|
"@rsbuild/core": "1.5.2",
|
|
42
42
|
"@rsbuild/plugin-eslint": "1.1.2",
|
|
43
43
|
"@rsbuild/plugin-react": "1.4.0",
|
|
@@ -48,7 +48,6 @@
|
|
|
48
48
|
"@types/qs": "6.9.7",
|
|
49
49
|
"@types/react": "18.3.3",
|
|
50
50
|
"@types/react-dom": "18.3.0",
|
|
51
|
-
"@vanilla-extract/webpack-plugin": "2.3.22",
|
|
52
51
|
"autoprefixer": "10.4.14",
|
|
53
52
|
"commitizen": "4.3.0",
|
|
54
53
|
"cross-env": "7.0.3",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { css } from '@/styled-system/css'
|
|
2
2
|
|
|
3
|
-
export const
|
|
3
|
+
export const rootCss = css({
|
|
4
4
|
display: 'flex',
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
justifyContent: 'center',
|
|
6
|
+
alignItems: 'center'
|
|
7
7
|
})
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { useHomeData } from '@/shared/service'
|
|
2
|
-
import
|
|
2
|
+
import { rootCss } from './view.css'
|
|
3
3
|
|
|
4
4
|
export default function Home() {
|
|
5
5
|
const { data } = useHomeData()
|
|
6
6
|
|
|
7
7
|
console.log('data', data)
|
|
8
8
|
|
|
9
|
-
return <div className={
|
|
9
|
+
return <div className={rootCss}>sdfs</div>
|
|
10
10
|
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { defineConfig } from '@pandacss/dev'
|
|
2
|
+
import { globalCss } from './global.css'
|
|
3
|
+
|
|
4
|
+
export default defineConfig({
|
|
5
|
+
// Whether to use css reset
|
|
6
|
+
preflight: true,
|
|
7
|
+
// Where to look for your css declarations
|
|
8
|
+
include: ['**/*.{js,jsx,ts,tsx}'],
|
|
9
|
+
// Files to exclude
|
|
10
|
+
exclude: [],
|
|
11
|
+
// Useful for theme customization
|
|
12
|
+
theme: {
|
|
13
|
+
extend: {}
|
|
14
|
+
},
|
|
15
|
+
// The output directory for your css system
|
|
16
|
+
outdir: 'styled-system',
|
|
17
|
+
globalCss
|
|
18
|
+
})
|
|
@@ -4,7 +4,6 @@ import { pluginEslint } from '@rsbuild/plugin-eslint'
|
|
|
4
4
|
import StylelintWebpackPlugin from 'stylelint-webpack-plugin'
|
|
5
5
|
import { pluginTypeCheck } from '@rsbuild/plugin-type-check'
|
|
6
6
|
import { RsdoctorRspackPlugin } from '@rsdoctor/rspack-plugin'
|
|
7
|
-
import { VanillaExtractPlugin } from '@vanilla-extract/webpack-plugin'
|
|
8
7
|
import { pluginSvgr } from '@rsbuild/plugin-svgr'
|
|
9
8
|
import { createChunks } from './scripts'
|
|
10
9
|
|
|
@@ -39,7 +38,6 @@ export default defineConfig(({ envMode, command }) => {
|
|
|
39
38
|
tools: {
|
|
40
39
|
rspack: {
|
|
41
40
|
plugins: [
|
|
42
|
-
new VanillaExtractPlugin(),
|
|
43
41
|
new StylelintWebpackPlugin(),
|
|
44
42
|
process.env.RSDOCTOR && new RsdoctorRspackPlugin()
|
|
45
43
|
]
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
})
|
|
1
|
+
import { defineGlobalStyles } from '@pandacss/dev'
|
|
2
|
+
|
|
3
|
+
export const globalCss = defineGlobalStyles({
|
|
4
|
+
'html, body': {}
|
|
5
|
+
})
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@layer reset, base, tokens, recipes, utilities;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { startApp } from '@/domain/app'
|
|
2
|
-
import './
|
|
3
|
-
|
|
4
|
-
startApp()
|
|
1
|
+
import { startApp } from '@/domain/app'
|
|
2
|
+
import './main.css'
|
|
3
|
+
|
|
4
|
+
startApp()
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"version": "0.0.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
7
|
-
"prepare": "husky
|
|
7
|
+
"prepare": "panda codegen && husky",
|
|
8
8
|
"dev": "vite",
|
|
9
9
|
"build": "tsc --noEmit && vite build",
|
|
10
10
|
"build:analyse": "tsc --noEmit && vite build --mode analyse",
|
|
@@ -19,7 +19,6 @@
|
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@tanstack/react-query": "5.51.15",
|
|
22
|
-
"@vanilla-extract/css": "1.17.4",
|
|
23
22
|
"axios": "1.7.9",
|
|
24
23
|
"define-zustand": "3.4.0",
|
|
25
24
|
"es-toolkit": "1.39.8",
|
|
@@ -39,11 +38,11 @@
|
|
|
39
38
|
"@emotion/babel-plugin": "11.13.5",
|
|
40
39
|
"@eslint/js": "9.15.0",
|
|
41
40
|
"@faker-js/faker": "8.4.1",
|
|
41
|
+
"@pandacss/dev": "1.2.0",
|
|
42
42
|
"@types/node": "18.16.0",
|
|
43
43
|
"@types/qs": "6.9.7",
|
|
44
44
|
"@types/react": "18.3.3",
|
|
45
45
|
"@types/react-dom": "18.3.0",
|
|
46
|
-
"@vanilla-extract/vite-plugin": "5.1.1",
|
|
47
46
|
"@vitejs/plugin-react": "5.0.1",
|
|
48
47
|
"autoprefixer": "10.4.14",
|
|
49
48
|
"commitizen": "4.3.0",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
export const
|
|
4
|
-
display: 'flex',
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
})
|
|
1
|
+
import { css } from '@/styled-system/css'
|
|
2
|
+
|
|
3
|
+
export const rootCss = css({
|
|
4
|
+
display: 'flex',
|
|
5
|
+
justifyContent: 'center',
|
|
6
|
+
alignItems: 'center'
|
|
7
|
+
})
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { useHomeData } from '@/shared/service'
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
export default function Home() {
|
|
5
|
-
const { data } = useHomeData()
|
|
6
|
-
|
|
7
|
-
console.log('data', data)
|
|
8
|
-
|
|
9
|
-
return <div className={
|
|
10
|
-
}
|
|
1
|
+
import { useHomeData } from '@/shared/service'
|
|
2
|
+
import { rootCss } from './view.css'
|
|
3
|
+
|
|
4
|
+
export default function Home() {
|
|
5
|
+
const { data } = useHomeData()
|
|
6
|
+
|
|
7
|
+
console.log('data', data)
|
|
8
|
+
|
|
9
|
+
return <div className={rootCss}>sdfs</div>
|
|
10
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { defineConfig } from '@pandacss/dev'
|
|
2
|
+
import { globalCss } from './global.css'
|
|
3
|
+
|
|
4
|
+
export default defineConfig({
|
|
5
|
+
// Whether to use css reset
|
|
6
|
+
preflight: true,
|
|
7
|
+
// Where to look for your css declarations
|
|
8
|
+
include: ['**/*.{js,jsx,ts,tsx}'],
|
|
9
|
+
// Files to exclude
|
|
10
|
+
exclude: [],
|
|
11
|
+
// Useful for theme customization
|
|
12
|
+
theme: {
|
|
13
|
+
extend: {}
|
|
14
|
+
},
|
|
15
|
+
// The output directory for your css system
|
|
16
|
+
outdir: 'styled-system',
|
|
17
|
+
globalCss
|
|
18
|
+
})
|
|
@@ -1,79 +1,63 @@
|
|
|
1
|
-
import { defineConfig, loadEnv } from 'vite'
|
|
2
|
-
import react from '@vitejs/plugin-react'
|
|
3
|
-
import svgr from 'vite-plugin-svgr'
|
|
4
|
-
import
|
|
5
|
-
import checker from 'vite-plugin-checker'
|
|
6
|
-
import { visualizer } from 'rollup-plugin-visualizer'
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
})
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
},
|
|
68
|
-
server: {
|
|
69
|
-
host: '0.0.0.0',
|
|
70
|
-
proxy: {
|
|
71
|
-
[proxyBaseUrl]: {
|
|
72
|
-
target: 'http://127.0.0.1',
|
|
73
|
-
changeOrigin: true,
|
|
74
|
-
rewrite: path => path.replace(proxyBaseUrl, '')
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
})
|
|
1
|
+
import { defineConfig, loadEnv } from 'vite'
|
|
2
|
+
import react from '@vitejs/plugin-react'
|
|
3
|
+
import svgr from 'vite-plugin-svgr'
|
|
4
|
+
import { mockDevServerPlugin } from 'vite-plugin-mock-dev-server'
|
|
5
|
+
import checker from 'vite-plugin-checker'
|
|
6
|
+
import { visualizer } from 'rollup-plugin-visualizer'
|
|
7
|
+
import { createChunks } from './scripts'
|
|
8
|
+
|
|
9
|
+
// https://vitejs.dev/config/
|
|
10
|
+
export default defineConfig(({ mode }) => {
|
|
11
|
+
const env = loadEnv(mode, process.cwd(), '')
|
|
12
|
+
const proxyBaseUrl = env.VITE_BASE_URL + env.VITE_API_HOST
|
|
13
|
+
const plugins: any[] = [
|
|
14
|
+
svgr(),
|
|
15
|
+
mockDevServerPlugin({
|
|
16
|
+
include: ['**/*.mock.{ts,js}']
|
|
17
|
+
}),
|
|
18
|
+
checker({
|
|
19
|
+
enableBuild: false,
|
|
20
|
+
typescript: true,
|
|
21
|
+
eslint: { useFlatConfig: true, lintCommand: 'eslint', dev: { logLevel: ['error'] } }
|
|
22
|
+
}),
|
|
23
|
+
react()
|
|
24
|
+
]
|
|
25
|
+
|
|
26
|
+
if (mode === 'analyse') {
|
|
27
|
+
plugins.push(visualizer({ open: true, sourcemap: true, brotliSize: true, gzipSize: true }))
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
return {
|
|
31
|
+
base: env.VITE_BASE_URL,
|
|
32
|
+
plugins,
|
|
33
|
+
resolve: {
|
|
34
|
+
alias: {
|
|
35
|
+
'@': __dirname
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
esbuild: {
|
|
39
|
+
drop: ['production', 'analyse'].includes(mode) ? ['console', 'debugger'] : []
|
|
40
|
+
},
|
|
41
|
+
build: {
|
|
42
|
+
sourcemap: mode === 'analyse',
|
|
43
|
+
reportCompressedSize: mode === 'analyse',
|
|
44
|
+
rollupOptions: {
|
|
45
|
+
output: {
|
|
46
|
+
manualChunks: createChunks({
|
|
47
|
+
react: ['react', 'react-dom']
|
|
48
|
+
})
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
server: {
|
|
53
|
+
host: '0.0.0.0',
|
|
54
|
+
proxy: {
|
|
55
|
+
[proxyBaseUrl]: {
|
|
56
|
+
target: 'http://127.0.0.1',
|
|
57
|
+
changeOrigin: true,
|
|
58
|
+
rewrite: path => path.replace(proxyBaseUrl, '')
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
})
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"private": true,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
7
|
-
"prepare": "husky
|
|
7
|
+
"prepare": "husky",
|
|
8
8
|
"dev": "cross-env MODE=development vite",
|
|
9
9
|
"build": "npm run check && npm run lint && cross-env MODE=production vite build",
|
|
10
10
|
"build:analyse": "npm run check && npm run lint && vite build --mode analyse",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './theme.css'
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './theme.css'
|