storybook: Latest version of Angular installs tapable 2.2.0 which conflicts with storybook 1.1.3 requirement
Describe the bug After installing storybook into a clean angular 11.0.4 project, tapable throws a number of errors while compiling typescript.
To Reproduce
- Create a fresh Angular 11.0.4 project.
- Init storybook.
- Run tsc.
Expected behavior tsc compiles without errors
Screenshots
Code snippets results:
node_modules/@types/webpack/index.d.ts:32:3 - error TS2305: Module '"../../tapable/tapable"' has no exported member 'Tapable'.
32 Tapable,
~~~~~~~
node_modules/@types/webpack/index.d.ts:1062:23 - error TS2707: Generic type 'SyncWaterfallHook<T, AdditionalOptions>' requires between 1 and 2 type arguments.
1062 resolver: SyncWaterfallHook;
~~~~~~~~~~~~~~~~~
and many more
System
Environment Info:
System:
OS: macOS 11.0.1
CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz
Binaries:
Node: 12.15.0 - ~/.nvm/versions/node/v12.15.0/bin/node
Yarn: 1.22.10 - ~/.nvm/versions/node/v12.15.0/bin/yarn
npm: 6.14.9 - ~/.nvm/versions/node/v12.15.0/bin/npm
Browsers:
Chrome: 87.0.4280.88
Edge: 87.0.664.60
Firefox: 80.0.1
Safari: 14.0.1
npmPackages:
@storybook/addon-actions: ^6.1.11 => 6.1.11
@storybook/addon-essentials: ^6.1.11 => 6.1.11
@storybook/addon-links: ^6.1.11 => 6.1.11
@storybook/angular: ^6.1.11 => 6.1.11
Additional context
I was able to resolve by forcing tsc 1.1.3, but unfortunately that will likely cause issues with angular dev kit which transiently requires 2.2.0.
angular-to-do@0.0.0
├─┬ @angular-devkit/build-angular@0.1100.4
│ ├─┬ @ngtools/webpack@11.0.4
│ │ └─┬ enhanced-resolve@5.3.1
│ │ └── tapable@2.2.0
│ └─┬ webpack@4.44.2
│ ├─┬ enhanced-resolve@4.3.0
│ │ └── tapable@1.1.3 deduped
│ └── tapable@1.1.3
└─┬ @storybook/angular@6.1.11
├─┬ @storybook/core@6.1.11
│ ├─┬ html-webpack-plugin@4.5.0
│ │ └── tapable@1.1.3
│ └─┬ react-dev-utils@10.2.1
│ └─┬ fork-ts-checker-webpack-plugin@3.1.1
│ └── tapable@1.1.3
├─┬ fork-ts-checker-webpack-plugin@4.1.6
│ └── tapable@1.1.3
├─┬ ts-loader@6.2.2
│ └─┬ enhanced-resolve@4.3.0
│ └── tapable@1.1.3
└─┬ tsconfig-paths-webpack-plugin@3.3.0
└─┬ enhanced-resolve@4.3.0
└── tapable@1.1.3
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 8
- Comments: 15 (4 by maintainers)
Commits related to this issue
- Fix build error See https://github.com/storybookjs/storybook/issues/13440 — committed to cockatoos/cockatoos-app by ansonmiu0214 3 years ago
Sorry @Imp0ssible but this a problem of StoryBook. Enabling skipLibCheck is not a valid solution for many projects.
it’s not storybook issue
"compilerOptions": { "skipLibCheck": true }Seeing the exact same in a project I’m upgrading to Angular 11 and Storybook 6.1.10
Automention: Hey @Marklb @MaximSagan @kroeder @ndelangen, you’ve been tagged! Can you give a hand here?