Skip to content

Commit

Permalink
重构 4.0 next 版本
Browse files Browse the repository at this point in the history
  • Loading branch information
xuliangzhan committed Nov 11, 2020
1 parent 5b3f5ab commit 623ef32
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ gulp.task('build_commonjs', function () {
gulp.task('build_umd', function () {
return gulp.src(['depend.ts', 'index.ts'])
.pipe(ts(tsconfig.compilerOptions))
.pipe(replace(`import XEUtils from 'xe-utils/ctor';`, `import XEUtils from 'xe-utils';`))
.pipe(replace('import XEUtils from \'xe-utils/ctor\';', 'import XEUtils from \'xe-utils\';'))
.pipe(babel({
moduleId: pack.name,
presets: [
Expand All @@ -40,13 +40,13 @@ gulp.task('build_umd', function () {
globals: {
[pack.name]: exportModuleName,
'xe-utils': 'XEUtils',
'jspdf': 'jspdf'
jspdf: 'jspdf'
},
exactGlobals: true
}]
]
}))
.pipe(replace(`global.jspdf`, `global.jsPDF || global.jspdf`))
.pipe(replace('global.jspdf', 'global.jsPDF || global.jspdf'))
.pipe(replace(`global.${exportModuleName} = mod.exports;`, `global.${exportModuleName} = mod.exports.default;`))
.pipe(rename({
basename: 'index',
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"prettier": "^2.1.2",
"typescript": "^4.0.5",
"vue": "^3.0.2",
"vxe-table": "^4.0.0-alpha.1",
"vxe-table": "^4.0.0-alpha.2",
"xe-utils": "^3.0.1"
},
"peerDependencies": {
Expand Down

0 comments on commit 623ef32

Please sign in to comment.