webpack
[暂停使用]日行一善
这个作者很懒,什么都没留下…
展开
-
commonJs
单个导出(exports.test1)、批量导出(module.exports) 使用时一定要注意~ 有个exports.default,没记~ // 首先exports相当于一个代理,exports.test1 = 1 等价于 module.exports.test1 = 1 // a.js exports.test1 = 1; module.exports = {name:'js ...原创 2019-03-24 20:43:29 · 950 阅读 · 0 评论 -
好玩的.externals&providePlugin
形成一个闭环~ const Webpack = require('webpack'); module.exports = function (config) { config.externals = config.externals || {}; Object.assign(config.externals, { 'axios': 'axios', 'react': 'Re...原创 2019-03-24 16:57:02 · 366 阅读 · 1 评论