Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After upgrade to 13.x storybook fails to compile #8580

Closed
jasedwards opened this issue Jan 18, 2022 · 8 comments
Closed

After upgrade to 13.x storybook fails to compile #8580

jasedwards opened this issue Jan 18, 2022 · 8 comments
Labels
outdated scope: angular Issues related to Angular support in Nx scope: storybook Issues related to Storybook support in Nx type: bug

Comments

@jasedwards
Copy link

Current Behavior

running nx storybook errors in compilation with following error:

Error: C:\code\upgrade\upgradetest\apps\myapp\src\polyfills.ts is missing from the TypeScript compilation. Please make sure it is in your tsconfig via the 'files' or 'include' property.
    at C:\code\upgrade\upgradetest\node_modules\@ngtools\webpack\src\ivy\loader.js:60:26
    at processResult (C:\code\upgrade\upgradetest\node_modules\webpack\lib\NormalModule.js:751:19)
    at C:\code\upgrade\upgradetest\node_modules\webpack\lib\NormalModule.js:853:5
    at C:\code\upgrade\upgradetest\node_modules\loader-runner\lib\LoaderRunner.js:399:11
    at C:\code\upgrade\upgradetest\node_modules\loader-runner\lib\LoaderRunner.js:251:18
    at context.callback (C:\code\upgrade\upgradetest\node_modules\loader-runner\lib\LoaderRunner.js:124:13)
    at C:\code\upgrade\upgradetest\node_modules\@ngtools\webpack\src\ivy\loader.js:60:17

Expected Behavior

It should compile

Steps to Reproduce

This can be reproduced by generating a new workspace with angular as the framework. I then created a library and ran storybook configuration command. I selected no when asked to create an e2e app. Then I just run nx storybook

Failure Logs

Error: C:\code\upgrade\upgradetest\apps\myapp\src\polyfills.ts is missing from the TypeScript compilation. Please make sure it is in your tsconfig via the 'files' or 'include' property.
    at C:\code\upgrade\upgradetest\node_modules\@ngtools\webpack\src\ivy\loader.js:60:26
    at processResult (C:\code\upgrade\upgradetest\node_modules\webpack\lib\NormalModule.js:751:19)
    at C:\code\upgrade\upgradetest\node_modules\webpack\lib\NormalModule.js:853:5
    at C:\code\upgrade\upgradetest\node_modules\loader-runner\lib\LoaderRunner.js:399:11
    at C:\code\upgrade\upgradetest\node_modules\loader-runner\lib\LoaderRunner.js:251:18
    at context.callback (C:\code\upgrade\upgradetest\node_modules\loader-runner\lib\LoaderRunner.js:124:13)
    at C:\code\upgrade\upgradetest\node_modules\@ngtools\webpack\src\ivy\loader.js:60:17

Environment

Node : 14.17.0
OS : win32 x64
npm : 6.14.13

nx : 13.4.5
@nrwl/angular : 13.4.5
@nrwl/cli : 13.4.5
@nrwl/cypress : 13.4.5
@nrwl/devkit : 13.4.5
@nrwl/eslint-plugin-nx : 13.4.5
@nrwl/express : undefined
@nrwl/jest : 13.4.5
@nrwl/linter : 13.4.5
@nrwl/nest : undefined
@nrwl/next : undefined
@nrwl/node : undefined
@nrwl/nx-cloud : undefined
@nrwl/react : undefined
@nrwl/react-native : undefined
@nrwl/schematics : undefined
@nrwl/tao : 13.4.5
@nrwl/web : undefined
@nrwl/workspace : 13.4.5
@nrwl/storybook : 13.4.5
@nrwl/gatsby : undefined
typescript : 4.4.4
rxjs : 7.4.0

Community plugins:
@angular/animations: 13.1.2
@angular/common: 13.1.2
@angular/compiler: 13.1.2
@angular/core: 13.1.2
@angular/forms: 13.1.2
@angular/platform-browser: 13.1.2
@angular/platform-browser-dynamic: 13.1.2
@angular/router: 13.1.2
@angular-devkit/build-angular: 13.1.3
@angular/cli: 13.1.3
@angular/compiler-cli: 13.1.2
@angular/language-service: 13.1.2
@storybook/angular: 6.4.13

@maro1993
Copy link

Facing the same issue

@jasedwards
Copy link
Author

I created a pull request showing this can be reproduced in nx-examples. it is linked above

@AlenNS
Copy link

AlenNS commented Jan 18, 2022

I'm having the same issue and it looks like it should be fixed with the next release.
#8494

@jasedwards
Copy link
Author

following this comment fixes the issue

@jasedwards
Copy link
Author

It looks like 13.4.6 has a fix for this.

@vsavkin vsavkin added scope: angular Issues related to Angular support in Nx scope: storybook Issues related to Storybook support in Nx labels Jan 20, 2022
@Coly010
Copy link
Contributor

Coly010 commented Jan 21, 2022

Duplicate of #8527

13.4.6 has been released, so it'll be worth trying again with the latest version of Nx.

I'm going to close this issue as it is a duplicate. If the issue persists, can you reply to the issue I've linked above so we can keep all conversations related to this issue in one place?

Thank you!!

@mandarini
Copy link
Member

New docs for styles and stylePreprocessorOptions

@github-actions
Copy link

This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
outdated scope: angular Issues related to Angular support in Nx scope: storybook Issues related to Storybook support in Nx type: bug
Projects
None yet
Development

No branches or pull requests

6 participants