I ran into this error after upgrading to 4.0.0 with my webpack build:
ERROR in ./~/css-loader!./~/postcss-loader!./~/normalize.css/normalize.css
Module build failed: TypeError: Cannot read property 'relative' of undefined
at C:\Users\user\Desktop\postcss-assets-4.0.0-error\node_modules\postcss-assets\index.js:32:20
at LazyResult.run (C:\Users\user\Desktop\postcss-assets-4.0.0-error\node_modules\postcss\lib\lazy-result.js:206:20)
at C:\Users\user\Desktop\postcss-assets-4.0.0-error\node_modules\postcss\lib\lazy-result.js:120:37
at LazyResult.asyncTick (C:\Users\user\Desktop\postcss-assets-4.0.0-error\node_modules\postcss\lib\lazy-result.js:134:15)
at processing.Promise.then._this2.processed (C:\Users\user\Desktop\postcss-assets-4.0.0-error\node_modules\postcss\lib\lazy-result.js:160:20)
at LazyResult.async (C:\Users\user\Desktop\postcss-assets-4.0.0-error\node_modules\postcss\lib\lazy-result.js:157:27)
at LazyResult.then (C:\Users\user\Desktop\postcss-assets-4.0.0-error\node_modules\postcss\lib\lazy-result.js:79:21)
at Object.module.exports (C:\Users\user\Desktop\postcss-assets-4.0.0-error\node_modules\postcss-loader\index.js:47:32)
@ ./~/normalize.css/normalize.css 4:14-96
I ran into this error after upgrading to
4.0.0
with my webpack build:To reproduce, simply clone this repo: https://github.com/F21/postcss-assets-4.0.0-error
Then run
npm install
andnpm run build
.