thgh / rollup-plugin-css-only

Rollup plugin that bundles imported css
MIT License
116 stars 27 forks source link

TypeError: Cannot read properties of null (reading 'importedIds') #48

Closed linyxria closed 2 years ago

linyxria commented 2 years ago

getModuleInfo(id).importedIds.forEach(function (importId) { modules = new Set( [].concat( Array.from(modules), Array.from(getCSSModules(importId, getModuleInfo, modules)) ) ); })

My rollup plugins configuration is as follows:

plugins: [ peerDepsExternal(), resolve(), commonjs(), typescript({ tsconfig: './tsconfig.json' }), linaria({ sourceMap: true, babelOptions: { presets: ['@babel/preset-typescript', '@babel/preset-react'], }, }), css({ output: 'styles.css', }), ]

terrywh commented 2 years ago

image

same here (after rollup update)

thgh commented 2 years ago

Not exactly sure what causes this, but a fix has been published in v4.2

Feel free to reopen and add a reproducible demo repo