zhangqw2
zhangqw2
解决了吗? 安装docx.js还是这个错
创建一个新项目引入可以,在旧的项目引入就报这个错
@PhoneixT 有解决吗?
config.module .rule('docx') .test(/node_modules\/@hufe921\/canvas-editor-plugin-docx\/dist\/docx.js/) .use() .loader('babel-loader') .end() 指定加载器为babel-loader可以
config.module .rule('docx') .test(/node_modules[\\/]@hufe921[\\/]canvas-editor-plugin-docx[\\/]dist[\\/]docx\.js/) .use() .loader('babel-loader') .end() windous系统用这个,windows系统和mac系统在路径引用方式上有区别
插件里面已经下载了,你搞清楚自己项目用的加载器是babel-loader还是file-loader,然后用正确路径指定加载器就行