我在webpack配置中有以下规则:
{
test: /(\.tsx?)$/,
use: [{
loader: 'thread-loader'
},
{
loader: 'ts-loader',
options: {
transpileOnly: true,
appendTsSuffixTo: [/\.vue$/]
}
}]
}
这会导致:
ERROR in ./plugins/axios.ts
Module build failed (from ./node_modules/thread-loader/dist/cjs.js):
Thread Loader (Worker 9)
Cannot read property 'errors' of undefined
如果我移除线程加载器,它就可以正常工作。