aackerman / circular-dependency-plugin

Detect circular dependencies in modules compiled with Webpack
https://www.npmjs.com/package/circular-dependency-plugin
ISC License
914 stars 46 forks source link

@types/circular-dependency-plugin is not compatible with Webpack 5 #79

Closed dko-slapdash closed 2 years ago

dko-slapdash commented 3 years ago

Hi.

@types/circular-dependency-plugin has a different webpack version dependency, so Compiler type is incompatible:

      Type '(compiler: import("/Users/d/Documents/git/slapdash/node_modules/@types/circular-dependency-plugin/node_modules/@types/webpack/index").Compiler) => void' is not assignable to type '(compiler: import("/Users/d/Documents/git/slapdash/node_modules/webpack/types").Compiler) => void'.
        Types of parameters 'compiler' and 'compiler' are incompatible.
          Type 'Compiler' is missing the following properties from type 'Compiler': _pluginCompat, _plugins, plugin, apply, and 17 more.
wdfinch commented 3 years ago

Also getting this

gbiryukov commented 2 years ago

Typings should support @5

If you getting this error this means your lock file pinned previous minor version of webpack as dependency for tis plugin resulting in types incompatibility.

You can use tool like yarn-deduplicate to fix your lock file and sync version back

aackerman commented 2 years ago

The project @types/circular-dependency-plugin is supported by a different maintainer