webpack保存路径

来源:互联网 发布:小米6怎么设置4g网络 编辑:程序博客网 时间:2024/06/05 04:17

说明路径有问题,解决方法:

var path = require("path");module.exports = {   entry: './src/script/main.js',  // 需要打包的路径   output: {       path: path.resolve(__dirname,'./dist/js'),     // 打包后存放的位置       filename: 'bundle.js'   // 打包后的名称    }}