nx: Storybook Install: "Could not read apps/ng-nest/tsconfig.lib.json"
Prerequisites
Please answer the following questions for yourself before submitting an issue. YOU MAY DELETE THE PREREQUISITES SECTION.
- [x ] I am running the latest version
- [ x] I checked the documentation (nx.dev) and found no answer
- [x ] I checked to make sure that this issue has not already been filed
- [x ] I’m reporting the issue to the correct repository (not related to React, Angular or any dependency)
Expected Behavior
The expected behavior is to be able to install Storybook integration given the documentation instructions.
Current Behavior
The current behavior when following the instructions for installing Storybook integration ends with an error “Could not read apps/ng-nest/tsconfig.lib.json” (which makes no sense, because the only tsconfig.lib.json in the project is in the libs/api-interfaces/tsconfig.lib.json, and I do not believe there would ever be a apps/ng-nest/tsconfig.lib.json file).
Failure Information (for bugs)
Please help provide information about the failure if this is a bug. If it is not a bug, please remove the rest of this template.
Steps to Reproduce
Please provide detailed steps for reproducing the issue.
npx create-nx-workspace@latest nx-test-workspaceWorkspace: angular-nest Application Name: ng-nest Default style: SCSS (.scss)cd nx-test-workspacenpx -p @storybook/cli sb initnx g @nrwl/angular:storybook-configuration ng-nestwhich fails with an error "Could not find module “@nrwl/storybook” from “/Users/leifwells/Code/nx-test-workspace”.npm i -D @nrwl/storybookto avoid the errornx g @nrwl/angular:storybook-configuration ng-nestwhich ends with the error “Could not read apps/ng-nest/tsconfig.lib.json”
Context
Please provide any relevant information about your setup:
@nrwl/angular : 8.11.2
@nrwl/cli : 8.11.2
@nrwl/cypress : 8.11.2
@nrwl/eslint-plugin-nx : Not Found
@nrwl/express : Not Found
@nrwl/jest : 8.11.2
@nrwl/linter : 8.11.2
@nrwl/nest : 8.11.2
@nrwl/next : Not Found
@nrwl/node : 8.11.2
@nrwl/react : Not Found
@nrwl/schematics : Not Found
@nrwl/tao : 8.11.2
@nrwl/web : Not Found
@nrwl/workspace : 8.11.2
typescript : 3.5.3
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 13
- Comments: 18 (2 by maintainers)
Commits related to this issue
- feat(storybook): storybook config projectType application (#2382) — committed to webberwang/nx by deleted user 4 years ago
- feat(storybook): storybook config projectType application (#2382) feat(storybook): add storybook config for projectType application (#2382) — committed to webberwang/nx by deleted user 4 years ago
- feat(storybook): storybook config projectType application (#2382) feat(storybook): add storybook config for projectType application (#2382) — committed to webberwang/nx by deleted user 4 years ago
- feat(storybook): allow stories for application (#2382) — committed to webberwang/nx by deleted user 4 years ago
- feat(storybook): storybook config projectType application (#2382) feat(storybook): add storybook config for projectType application (#2382) feat(storybook): allow stories for application (#2382) f... — committed to webberwang/nx by deleted user 4 years ago
- feat(storybook): storybook config projectType application (#2382) (#3611) * feat(storybook): storybook config projectType application * docs(storybook): update auto-generated docs * feat(storyb... — committed to nrwl/nx by deleted user 4 years ago
- feat(storybook): storybook config projectType application (#2382) (#3611) * feat(storybook): storybook config projectType application * docs(storybook): update auto-generated docs * feat(storyb... — committed to vivekmore/nx by deleted user 4 years ago
- feat(storybook): storybook config projectType application (#2382) (#3611) * feat(storybook): storybook config projectType application * docs(storybook): update auto-generated docs * feat(storyb... — committed to Doginal/nx by deleted user 4 years ago
Hi, same issue on my side, it feels inappropriate to say that Storybook can only be used for libs… Looking forward to a fix! 👍
At a guess, it should be
tsconfig.app.json. The root leveltsconfig.jsonfile is more for project-wide configuration that’s agnostic to whether the inheritor is anappor alib. But since you don’t target Storybook towards a generic ‘everything’ but instead a specific app or lib within a monorepo,tsconfig.app.jsonmakes more sense to me.@ctaepper Can you tell me how I can do this?
@FrozenPandaz I fixed this in https://github.com/nrwl/nx/pull/3611, added some unit tests as well. Let me know if anything needs to be changed.
Hi, any update on this matter?