我正在尝试在开发人员模式下运行Web kit,但是mini-css-extract-plugin
模块的构建失败,每个CSS文件一次。让我发布其中一些:
error in ./node_modules/vue-multiselect/dist/vue-multiselect.min.css
Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
ModuleBuildError: Module build failed (from ./node_modules/vue-style-loader/index.js):
TypeError: Cannot read property 'target' of undefined
at Object.module.exports.pitch (/var/www/VueFrontEnd/node_modules/vue-style-loader/index.js:15:31)
at runLoaders (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:301:20)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:367:11
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:182:20
at runSyncOrAsync (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:143:3)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:178:3
at loadLoader (/var/www/VueFrontEnd/node_modules/loader-runner/lib/loadLoader.js:47:3)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:169:2)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:165:10)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:176:18
at loadLoader (/var/www/VueFrontEnd/node_modules/loader-runner/lib/loadLoader.js:47:3)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:169:2)
at runLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:365:2)
at NormalModule.doBuild (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:280:3)
at NormalModule.build (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:427:15)
at Compilation.buildModule (/var/www/VueFrontEnd/node_modules/webpack/lib/Compilation.js:635:10)
at moduleFactory.create (/var/www/VueFrontEnd/node_modules/webpack/lib/Compilation.js:1021:12)
@ ./src/main.js 16:0-54
@ multi ./build/dev-client ./src/main.js
error in ./node_modules/leaflet/dist/leaflet.css
Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
ModuleBuildError: Module build failed (from ./node_modules/vue-style-loader/index.js):
TypeError: Cannot read property 'target' of undefined
at Object.module.exports.pitch (/var/www/VueFrontEnd/node_modules/vue-style-loader/index.js:15:31)
at runLoaders (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:301:20)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:367:11
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:182:20
at runSyncOrAsync (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:143:3)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:178:3
at loadLoader (/var/www/VueFrontEnd/node_modules/loader-runner/lib/loadLoader.js:47:3)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:169:2)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:165:10)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:176:18
at loadLoader (/var/www/VueFrontEnd/node_modules/loader-runner/lib/loadLoader.js:47:3)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:169:2)
at runLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:365:2)
at NormalModule.doBuild (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:280:3)
at NormalModule.build (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:427:15)
at Compilation.buildModule (/var/www/VueFrontEnd/node_modules/webpack/lib/Compilation.js:635:10)
at moduleFactory.create (/var/www/VueFrontEnd/node_modules/webpack/lib/Compilation.js:1021:12)
@ ./src/pages/Displays/NewDisplayWizard/Page3.vue?vue&type=script&lang=js& 95:0-35
@ ./src/pages/Displays/NewDisplayWizard/Page3.vue
@ ./src/router/index.js
@ ./src/main.js
@ multi ./build/dev-client ./src/main.js
error in ./node_modules/leaflet-loading/src/Control.Loading.css
Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
ModuleBuildError: Module build failed (from ./node_modules/vue-style-loader/index.js):
TypeError: Cannot read property 'target' of undefined
at Object.module.exports.pitch (/var/www/VueFrontEnd/node_modules/vue-style-loader/index.js:15:31)
at runLoaders (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:301:20)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:367:11
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:182:20
at runSyncOrAsync (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:143:3)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:178:3
at loadLoader (/var/www/VueFrontEnd/node_modules/loader-runner/lib/loadLoader.js:47:3)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:169:2)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:165:10)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:176:18
at loadLoader (/var/www/VueFrontEnd/node_modules/loader-runner/lib/loadLoader.js:47:3)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:169:2)
at runLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:365:2)
at NormalModule.doBuild (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:280:3)
at NormalModule.build (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:427:15)
at Compilation.buildModule (/var/www/VueFrontEnd/node_modules/webpack/lib/Compilation.js:635:10)
at moduleFactory.create (/var/www/VueFrontEnd/node_modules/webpack/lib/Compilation.js:1021:12)
@ ./src/pages/Scheduling/SchedulingMap.vue?vue&type=script&lang=js& 55:0-50
@ ./src/pages/Scheduling/SchedulingMap.vue
@ ./src/router/index.js
@ ./src/main.js
@ multi ./build/dev-client ./src/main.js
error in ./node_modules/leaflet-sidebar/src/L.Control.Sidebar.css
Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
ModuleBuildError: Module build failed (from ./node_modules/vue-style-loader/index.js):
TypeError: Cannot read property 'target' of undefined
at Object.module.exports.pitch (/var/www/VueFrontEnd/node_modules/vue-style-loader/index.js:15:31)
at runLoaders (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:301:20)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:367:11
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:182:20
at runSyncOrAsync (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:143:3)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:178:3
at loadLoader (/var/www/VueFrontEnd/node_modules/loader-runner/lib/loadLoader.js:47:3)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:169:2)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:165:10)
at /var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:176:18
at loadLoader (/var/www/VueFrontEnd/node_modules/loader-runner/lib/loadLoader.js:47:3)
at iteratePitchingLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:169:2)
at runLoaders (/var/www/VueFrontEnd/node_modules/loader-runner/lib/LoaderRunner.js:365:2)
at NormalModule.doBuild (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:280:3)
at NormalModule.build (/var/www/VueFrontEnd/node_modules/webpack/lib/NormalModule.js:427:15)
at Compilation.buildModule (/var/www/VueFrontEnd/node_modules/webpack/lib/Compilation.js:635:10)
at moduleFactory.create (/var/www/VueFrontEnd/node_modules/webpack/lib/Compilation.js:1021:12)
@ ./src/pages/Scheduling/SchedulingMap.vue?vue&type=script&lang=js& 52:0-52
@ ./src/pages/Scheduling/SchedulingMap.vue
@ ./src/router/index.js
@ ./src/main.js
@ multi ./build/dev-client ./src/main.js
在这里定义它:
{
test: /\.css$/,
use: [
{
loader: MiniCssExtractPlugin.loader,
},
"css-loader"
]
},
然后:
new MiniCssExtractPlugin({
filename: '[name]-bundle.css'
})
我会很感激。