question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

node_modules/tapable/tapable"' has no exported member 'Tapable'.

See original GitHub issue

I am trying to build angular8 app with webpack5+. in my try while I build the app, I am getting following error, as well If I am wrong way to create the app with webpack 5+ please show me the right direction.

ERROR in node_modules/@types/webpack/index.d.ts(32,3): error TS2305: Module '"../../../../myAngularApp/node_modules/tapable/tapable"' has no exported member 'Tapable'.
node_modules/@types/webpack/index.d.ts(1062,23): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1063,22): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1064,28): error TS2707: Generic type 'AsyncSeriesWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1065,27): error TS2707: Generic type 'AsyncSeriesWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1066,27): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1067,21): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1068,27): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1070,30): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1071,24): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1080,33): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1081,27): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1082,37): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1083,44): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1084,47): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1085,28): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1086,30): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1087,24): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1088,25): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1089,34): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1090,25): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1091,31): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1092,36): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1093,35): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1094,34): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1095,40): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1096,33): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1097,36): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1098,38): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1099,36): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1100,28): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1101,25): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1102,27): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1103,25): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1104,29): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1105,23): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1106,32): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1107,22): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1108,29): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1109,38): error TS2314: Generic type 'HookMap<H>' requires 1 type argument(s).
node_modules/@types/webpack/index.d.ts(1110,48): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1111,44): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1112,26): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1121,28): error TS2707: Generic type 'AsyncSeriesWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1122,27): error TS2707: Generic type 'AsyncSeriesWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1123,33): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1124,27): error TS2707: Generic type 'AsyncSeriesWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1144,21): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1145,19): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1147,40): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1148,35): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1149,43): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1152,23): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1154,35): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1155,30): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1156,38): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1171,27): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1190,25): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1191,24): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1197,33): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1198,40): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1199,32): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1204,31): error TS2707: Generic type 'AsyncSeriesHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1210,33): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1211,24): error TS2707: Generic type 'AsyncSeriesHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1219,33): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1220,28): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1224,43): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1225,38): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1226,46): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1239,27): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1240,22): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1241,32): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1242,28): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1243,24): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1244,27): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1258,22): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1259,21): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1260,21): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1261,22): error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1262,19): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1356,25): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1358,29): error TS2707: Generic type 'AsyncSeriesHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
node_modules/@types/webpack/index.d.ts(1374,25): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1375,26): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1376,31): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1379,26): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' requires between 2 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1399,25): error TS2707: Generic type 'SyncHook<T, R, AdditionalOptions>' requires between 1 and 3 type arguments.
node_modules/@types/webpack/index.d.ts(1466,24): error TS2707: Generic type 'SyncBailHook<T, R, AdditionalOptions>' 
```requires between 2 and 3 type arguments.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:13
  • Comments:13 (3 by maintainers)

github_iconTop GitHub Comments

70reactions
semtyrecommented, Jan 22, 2021

This issue is not directly related to webpack 5, but may I include some comments to help other people that will Google the error message and end up here?

It also happened to me for the following reasons:

  • webpack@5.11.1 depends on tapable@^2.1.1
  • the current version of html-webpack-plugin@4.5.1, a very popular plugin, depends on @types/webpack@4.41.25
  • @types/webpack@4.41.25 depends on a previous version of tapable, and is incompatible with tapable@^2.1.1
  • typescript, by default, will compile everything under node_modules/@types, and, even if you have a compatible version of @types/tapable, it will resolve to the incompatible version in node_modules/tapable
  • there is no @types/webpack@^5.X.X yet

EDIT: there is a beta version for html-webpack-plugin specific to webpack 5 (that is not dependent on @types/webpack):

  npm i --save-dev html-webpack-plugin@next
  yarn add --dev html-webpack-plugin@next

A quick workaround: Add "skipLibCheck": true to your tsconfig.json. That will tell tsc to skip node_modules all together.

36reactions
csvancommented, Dec 13, 2020

This has nothing to do with webpack. You need to fix whatever is doing that import since it is trying to import something that doesn’t exist.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Module '"tapable"' has no exported member 'Tapable'
I found that the problem was the path of the import statement. Webpack was importing Tapable from node_modules/tapable when it would have ......
Read more >
Latest version of Angular installs tapable 2.2.0 ... - Issuehunt
node_modules/@types/webpack/index.d.ts:32:3 - error TS2305: Module '"../../tapable/tapable"' has no exported member 'Tapable'. 32 Tapable ...
Read more >
generic type 'ɵɵcomponentdeclaration' requires ... - You.com
Now I have node module errors. ... myAngularApp/node_modules/tapable/tapable"' has no exported member 'Tapable'. node_modules/@types/webpack/index.d.ts(1062 ...
Read more >
tapable - npm
Start using tapable in your project by running `npm i tapable`. ... tapable. TypeScript icon, indicating that this package has built-in type ...
Read more >
error TS2305 - ADocLib
module has no exported member typescript exports and exports. ... Safely Managing Secrets with Node.js and Google Secret Manager You can use services...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found