swico 0.8.5-beta1 → 0.8.5-beta11
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 +19 -21
- package/src/config/webpack.base.vue.d.ts +17 -9
- package/src/config/webpack.base.vue.js +19 -26
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "swico",
|
|
3
|
-
"version": "0.8.5-
|
|
3
|
+
"version": "0.8.5-beta11",
|
|
4
4
|
"description": "Simple, efficient, and practical front-end framework",
|
|
5
5
|
"main": "./src/index.js",
|
|
6
6
|
"types": "./src/index.d.ts",
|
|
@@ -30,27 +30,35 @@
|
|
|
30
30
|
"author": "scw",
|
|
31
31
|
"license": "ISC",
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"history": "5.3.0",
|
|
34
33
|
"react": "~18.2.0",
|
|
35
34
|
"react-dom": "~18.2.0",
|
|
36
35
|
"react-router-dom": "6.22.3",
|
|
37
36
|
"vue": "~3.4.14",
|
|
38
|
-
"vue-router": "^4.2.5"
|
|
37
|
+
"vue-router": "^4.2.5",
|
|
38
|
+
"history": "5.3.0"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@babel/plugin-transform-runtime": "^7.24.3",
|
|
42
|
-
"@babel/preset-env": "^7.24.4",
|
|
43
41
|
"@babel/types": "7.23.9",
|
|
42
|
+
"@types/react": "18.2.79",
|
|
43
|
+
"@types/react-dom": "18.2.25",
|
|
44
|
+
"@vue/compiler-sfc": "3.4.14",
|
|
45
|
+
"eslint-plugin-react": "7.33.2",
|
|
46
|
+
"eslint-plugin-react-hooks": "4.3.0",
|
|
47
|
+
"eslint-plugin-vue": "9.19.2",
|
|
48
|
+
"vue-loader": "17.4.2",
|
|
49
|
+
"vue-style-loader": "4.1.3",
|
|
50
|
+
"webpack": "5.88.2",
|
|
51
|
+
"webpack-bundle-analyzer": "4.9.1",
|
|
52
|
+
"webpack-cli": "5.1.4",
|
|
53
|
+
"webpack-dev-server": "4.15.2",
|
|
54
|
+
"webpack-merge": "5.9.0",
|
|
55
|
+
"webpackbar": "6.0.1",
|
|
44
56
|
"@commitlint/cli": "18.5.0",
|
|
45
57
|
"@commitlint/config-conventional": "18.5.0",
|
|
46
58
|
"@swc/core": "1.4.6",
|
|
47
|
-
"@types/react": "18.2.79",
|
|
48
|
-
"@types/react-dom": "18.2.25",
|
|
49
59
|
"@typescript-eslint/eslint-plugin": "6.19.0",
|
|
50
60
|
"@typescript-eslint/parser": "6.19.0",
|
|
51
|
-
"@vue/compiler-sfc": "3.4.14",
|
|
52
61
|
"autoprefixer": "10.3.7",
|
|
53
|
-
"babel-loader": "^9.1.3",
|
|
54
62
|
"chalk": "4.1.2",
|
|
55
63
|
"chokidar": "3.6.0",
|
|
56
64
|
"commander": "12.0.0",
|
|
@@ -60,9 +68,6 @@
|
|
|
60
68
|
"css-loader": "6.3.0",
|
|
61
69
|
"esbuild-loader": "4.0.3",
|
|
62
70
|
"eslint": "8.48.0",
|
|
63
|
-
"eslint-plugin-react": "7.33.2",
|
|
64
|
-
"eslint-plugin-react-hooks": "4.3.0",
|
|
65
|
-
"eslint-plugin-vue": "9.19.2",
|
|
66
71
|
"eslint-webpack-plugin": "4.0.0",
|
|
67
72
|
"fork-ts-checker-webpack-plugin": "9.0.2",
|
|
68
73
|
"html-loader": "5.0.0",
|
|
@@ -80,14 +85,7 @@
|
|
|
80
85
|
"style-loader": "3.3.0",
|
|
81
86
|
"swc-loader": "0.2.6",
|
|
82
87
|
"ts-node": "10.9.1",
|
|
83
|
-
"
|
|
84
|
-
"
|
|
85
|
-
"vue-style-loader": "4.1.3",
|
|
86
|
-
"webpack": "5.88.2",
|
|
87
|
-
"webpack-bundle-analyzer": "4.9.1",
|
|
88
|
-
"webpack-cli": "5.1.4",
|
|
89
|
-
"webpack-dev-server": "4.15.2",
|
|
90
|
-
"webpack-merge": "5.9.0",
|
|
91
|
-
"webpackbar": "6.0.1"
|
|
88
|
+
"ts-loader": "9.5.1",
|
|
89
|
+
"typescript": "5.3.3"
|
|
92
90
|
}
|
|
93
91
|
}
|
|
@@ -22,21 +22,29 @@ export default function ({ projectPath, entryPath, env, customConfig }: GlobalDa
|
|
|
22
22
|
} | {
|
|
23
23
|
test: RegExp;
|
|
24
24
|
exclude: RegExp;
|
|
25
|
-
use:
|
|
25
|
+
use: {
|
|
26
26
|
loader: string;
|
|
27
27
|
options: {
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
jsc: {
|
|
29
|
+
parser: {
|
|
30
|
+
decorators: boolean;
|
|
31
|
+
dynamicImport: boolean;
|
|
32
|
+
};
|
|
33
|
+
target: string;
|
|
34
|
+
};
|
|
31
35
|
};
|
|
32
|
-
}
|
|
36
|
+
}[];
|
|
37
|
+
loader?: undefined;
|
|
38
|
+
oneOf?: undefined;
|
|
39
|
+
} | {
|
|
40
|
+
test: RegExp;
|
|
41
|
+
exclude: RegExp;
|
|
42
|
+
use: {
|
|
33
43
|
loader: string;
|
|
34
44
|
options: {
|
|
35
|
-
|
|
36
|
-
presets?: undefined;
|
|
37
|
-
plugins?: undefined;
|
|
45
|
+
appendTsSuffixTo: RegExp[];
|
|
38
46
|
};
|
|
39
|
-
}
|
|
47
|
+
};
|
|
40
48
|
loader?: undefined;
|
|
41
49
|
oneOf?: undefined;
|
|
42
50
|
} | {
|
|
@@ -63,10 +63,8 @@ var path_1 = __importDefault(require("path"));
|
|
|
63
63
|
var mini_css_extract_plugin_1 = __importDefault(require("mini-css-extract-plugin"));
|
|
64
64
|
var config_1 = require("../utils/config");
|
|
65
65
|
var html_webpack_plugin_1 = __importDefault(require("html-webpack-plugin"));
|
|
66
|
-
var fork_ts_checker_webpack_plugin_1 = __importDefault(require("fork-ts-checker-webpack-plugin"));
|
|
67
66
|
var webpack_1 = __importDefault(require("webpack"));
|
|
68
67
|
var vue_loader_1 = require("vue-loader");
|
|
69
|
-
var tools_1 = require("../utils/tools");
|
|
70
68
|
function default_1(_a) {
|
|
71
69
|
var _b, _c, _d;
|
|
72
70
|
var projectPath = _a.projectPath, entryPath = _a.entryPath, env = _a.env, customConfig = _a.customConfig;
|
|
@@ -117,24 +115,33 @@ function default_1(_a) {
|
|
|
117
115
|
exclude: /node_modules/
|
|
118
116
|
},
|
|
119
117
|
{
|
|
120
|
-
test: /\.
|
|
118
|
+
test: /\.js$/,
|
|
121
119
|
exclude: /node_modules/,
|
|
122
120
|
use: [
|
|
123
121
|
{
|
|
124
|
-
loader: '
|
|
125
|
-
options: {
|
|
126
|
-
presets: ['@babel/preset-env'],
|
|
127
|
-
plugins: ['@babel/plugin-transform-runtime']
|
|
128
|
-
}
|
|
129
|
-
},
|
|
130
|
-
{
|
|
131
|
-
loader: 'ts-loader',
|
|
122
|
+
loader: 'swc-loader',
|
|
132
123
|
options: {
|
|
133
|
-
|
|
124
|
+
jsc: {
|
|
125
|
+
parser: {
|
|
126
|
+
decorators: true,
|
|
127
|
+
dynamicImport: true
|
|
128
|
+
},
|
|
129
|
+
target: 'es2015'
|
|
130
|
+
}
|
|
134
131
|
}
|
|
135
132
|
}
|
|
136
133
|
]
|
|
137
134
|
},
|
|
135
|
+
{
|
|
136
|
+
test: /\.ts$/,
|
|
137
|
+
exclude: /node_modules/,
|
|
138
|
+
use: {
|
|
139
|
+
loader: 'ts-loader',
|
|
140
|
+
options: {
|
|
141
|
+
appendTsSuffixTo: [/\.vue$/]
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
},
|
|
138
145
|
{
|
|
139
146
|
oneOf: [
|
|
140
147
|
{
|
|
@@ -276,20 +283,6 @@ function default_1(_a) {
|
|
|
276
283
|
},
|
|
277
284
|
hash: true
|
|
278
285
|
}),
|
|
279
|
-
new fork_ts_checker_webpack_plugin_1.default({
|
|
280
|
-
logger: {
|
|
281
|
-
log: function () { },
|
|
282
|
-
error: function (message) {
|
|
283
|
-
tools_1.toast.error(message, { title: 'TypeScript errors' });
|
|
284
|
-
}
|
|
285
|
-
},
|
|
286
|
-
typescript: {
|
|
287
|
-
diagnosticOptions: {
|
|
288
|
-
semantic: true,
|
|
289
|
-
syntactic: true
|
|
290
|
-
}
|
|
291
|
-
}
|
|
292
|
-
}),
|
|
293
286
|
new mini_css_extract_plugin_1.default({
|
|
294
287
|
filename: env === 'dev' ? 'css/[name].css' : 'css/[name].[contenthash].css',
|
|
295
288
|
ignoreOrder: true
|