1
module.exports = { entry: './index.js', output: { filename: 'index.min.js', path: './' }, module: { loaders: [ { test: /\.js$/, loader: 'babel', exclude: /node_modules/, query: { presets: ['es2015'], plugins: ['transform-runtime'] }, cacheDirectory: true } ] } }
const pi = 3.14159265; let s = "Hello"; for (let codePoint of s) { console.log(codePoint); }
當我刪除的「排除」行了,編譯後的文件變成大約兩倍,它拋出錯誤:「$擴展是不是一個函數」。「排除」通天裝載機的選項的WebPack
我想知道爲什麼排除選項對編譯過程有影響。我只編譯./index.js