Closed
Description
I seem to be getting Cannot read property 'split' of undefined
on ubuntu 14.04 on node 8
Here is the config:
{
test: /\.css$/,
use: [{
loader: MiniCssExtractPlugin.loader,
options: {
root: path.join(__dirname, '../..')
}
}, {
loader: 'postcss-loader',
options: { config: { path: POSTCSS_PATH } }
}]
}
Here is the output:
�[91m/usr/local/loom/node_modules/mini-css-extract-plugin/dist/index.js:81
const resource = this._identifier.split('!').pop();
^
TypeError: Cannot read property 'split' of undefined
at CssModule.nameForCondition (/usr/local/loom/node_modules/mini-css-extract-plugin/dist/index.js:81:39)
at Function.checkTest (/usr/local/loom/node_modules/webpack/lib/optimize/SplitChunksPlugin.js:255:52)
at Object.fn [as getCacheGroups] (/usr/local/loom/node_modules/webpack/lib/optimize/SplitChunksPlugin.js:209:35)
at compilation.hooks.optimizeChunksAdvanced.tap.chunks (/usr/local/loom/node_modules/webpack/lib/optimize/SplitChunksPlugin.js:361:38)
at SyncBailHook.eval (eval at create (/usr/local/loom/node_modules/tapable/lib/HookCodeFactory.js:17:12), <anonymous>:12:16)
at SyncBailHook.lazyCompileHook [as _call] (/usr/local/loom/node_modules/tapable/lib/Hook.js:35:21)
at Compilation.seal (/usr/local/loom/node_modules/webpack/lib/Compilation.js:884:38)
at hooks.make.callAsync.err (/usr/local/loom/node_modules/webpack/lib/Compiler.js:481:17)
at _done (eval at create (/usr/local/loom/node_modules/tapable/lib/HookCodeFactory.js:24:12), <anonymous>:9:1)
at _err30 (eval at create (/usr/local/loom/node_modules/tapable/lib/HookCodeFactory.js:24:12), <anonymous>:380:22)
at _addModuleChain (/usr/local/loom/node_modules/webpack/lib/Compilation.js:758:12)
at processModuleDependencies.err (/usr/local/loom/node_modules/webpack/lib/Compilation.js:697:9)
at _combinedTickCallback (internal/process/next_tick.js:131:7)
at process._tickDomainCallback (internal/process/next_tick.js:218:9)
Do you see anything wrong with the config?
Between not being able to use https://github.com/webpack-contrib/extract-text-webpack-plugin and this error, it seems that upgrading to webpack 4 is not happening if one wants to take out their css into separate files
Metadata
Metadata
Assignees
Labels
No labels