无法输出打包后的文件。
var config = {
entry: './index.js',
output: {
path: './',
filename: 'bundle.js'
},
devServer: {
inline: true,
port: 7777
},
module: {
loaders: [
{text: /.js?$/, exclude: /node_modules/, loader: 'babel', query: {presets: ['es2015', 'react']}}
]
}
}
module.export = config;
这是webpack.config.js
在index.html中引入的 ./bundle.js 但是控制台显示找不到这个文件,会是什么原因呢?
那你至少得确定,和
index.html
同目录下,是否有bundle.js
文件