akfun 3.2.1 → 3.2.2
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
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "akfun",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.2",
|
|
4
4
|
"description": "前端脚手架:支持Vue技术栈和react技术栈",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"前端工程",
|
|
@@ -74,6 +74,7 @@
|
|
|
74
74
|
"@rollup/plugin-json": "^4.1.0",
|
|
75
75
|
"@rollup/plugin-node-resolve": "^13.1.3",
|
|
76
76
|
"@rollup/plugin-typescript": "^8.3.1",
|
|
77
|
+
"rollup-plugin-node-externals": "^4.0.0",
|
|
77
78
|
"@typescript-eslint/eslint-plugin": "^5.10.2",
|
|
78
79
|
"@typescript-eslint/parser": "^5.10.2",
|
|
79
80
|
"@vue/compiler-sfc": "^3.2.29",
|
|
@@ -19,7 +19,7 @@ const nested = require('postcss-nested');
|
|
|
19
19
|
const postcssPresetEnv = require('postcss-preset-env');
|
|
20
20
|
// css代码压缩
|
|
21
21
|
const cssnano = require('cssnano');
|
|
22
|
-
|
|
22
|
+
const { externals } = require('rollup-plugin-node-externals');
|
|
23
23
|
const { resolveToCurrentRoot, resolveToCurrentDist } = require('../utils/pathUtils'); // 统一路径解析
|
|
24
24
|
const babelConfig = require('./babel.config'); // Babel的配置文件
|
|
25
25
|
const projectConfig = require('./index'); // 引入当前项目配置文件
|
|
@@ -45,17 +45,19 @@ module.exports = function (fileName, akfunConfig) {
|
|
|
45
45
|
banner: buildBanner,
|
|
46
46
|
// format: build2esm.format || 'esm', // 生成包的格式
|
|
47
47
|
input: rollupInput,
|
|
48
|
-
/**
|
|
49
|
-
* external:(在akfun.config.js中配置)
|
|
50
|
-
* 需要一个 id 并返回 true(外部引用)或 false(不是外部的引用), 或者 Array 应该保留在bundle的外部引用的模块ID。
|
|
51
|
-
*/
|
|
52
|
-
external: build2esm.external || [],
|
|
53
48
|
plugins: [
|
|
54
49
|
alias({
|
|
55
50
|
resolve: curConfig.webpack.resolve.extensions,
|
|
56
51
|
extensions: curConfig.webpack.resolve.extensions,
|
|
57
52
|
entries: curConfig.webpack.resolve.alias
|
|
58
53
|
}),
|
|
54
|
+
/**
|
|
55
|
+
* excludeList(在akfun.config.js中配置)
|
|
56
|
+
* 设置打包中应该排除的依赖
|
|
57
|
+
*/
|
|
58
|
+
externals({
|
|
59
|
+
include: build2esm.excludeList || []
|
|
60
|
+
}),
|
|
59
61
|
nodeResolve({
|
|
60
62
|
extensions: curConfig.webpack.resolve.extensions
|
|
61
63
|
}),
|