You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't have a minimal repro config at the moment, but it seems like when compiling a Webpack config file from TS to JS* using tsc --build, the following errors appear:
node_modules/webpack-build-notifier/dist/types.d.ts:59:44 - error TS2724: 'exports' has no exported member named 'compiler'. Did you mean 'Compiler'?
59 onCompileStart?: (compilation: webpack.compiler.Compiler) => void;
~~~~~~~~
node_modules/webpack-build-notifier/dist/types.d.ts:65:40 - error TS2724: 'exports' has no exported member named 'compilation'. Did you mean 'Compilation'?
65 onComplete?: (compilation: webpack.compilation.Compilation, status: CompilationStatus) => void;
I also had to install @types/node-notifier on my repo to silence a few errors (I'm happy to post them as well), which is super weird, but at least it was easy to fix.
Is there any workaround I could use?
Versions:
node: 14.17.3
yarn: 1.22.17
webpack: 5.63.0
webpack-build-notifier: 2.3.0
ts-loader: 9.2.6
typescript: 4.4.4
* Context is that we have a shared Webpack config for all our repositories, that we write in TypeScript, then compile into a regular JS package.
The text was updated successfully, but these errors were encountered:
Hmm, so I suspect the issue is that webpack-build-notifier depends on webpack@4.x and your project is dependent upon webpack@5.x, and there is a type discrepancy between versions.
Regardless, I don't think your TS build should be transpiling (or type-checking) the webpack-build-notifier package. Does your tsconfig exclude node_modules?
I don't have a minimal repro config at the moment, but it seems like when compiling a Webpack config file from TS to JS* using
tsc --build
, the following errors appear:I also had to install
@types/node-notifier
on my repo to silence a few errors (I'm happy to post them as well), which is super weird, but at least it was easy to fix.Is there any workaround I could use?
Versions:
* Context is that we have a shared Webpack config for all our repositories, that we write in TypeScript, then compile into a regular JS package.
The text was updated successfully, but these errors were encountered: