-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
Docs: add message that storybook creates node_modules in pnp #25988
Docs: add message that storybook creates node_modules in pnp #25988
Conversation
@jonniebigodes I'm really looking forward to your feedback on that pr |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@turtle601 appreciate you taking the time to put together this pull request and helping us improve our documentation by adding this small but rather important piece of information that is affecting you and can affect other users as well. I left a small item for you to look into when you have a moment.
Let me know of any questions you may have so that I can unblock you and get this merged.
Looking forward to hearing from you.
Have a fantastic day.
Stay safe
docs/get-started/install.md
Outdated
<Callout variant="info"> | ||
|
||
If your repo is in PnP (Plug And Play) mode, node_modules may be installed when run. | ||
because Storybook's cache directory is located in the node_modules folder, since it is normally not checked in via version control. | ||
|
||
</Callout> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@turtle601 we have a bit of room for improvement here, If don't mind, can you remove this callout and instead add an entry in the troubleshooting section below as follows:
#### Yarn Plug'n'Play (PnP) support with Storybook
If you've enabled Storybook in a project running on a new version of Yarn with [Plug'n'Play](https://yarnpkg.com/features/pnp) (PnP) enabled, you may notice that it will generate `node_modules` with some additional files and folders. This is a known constraint as Storybook relies on some directories (e.g., `.cache`) to store cache files and other data to improve performance and faster builds. You can safely ignore these files and folders, adjusting your `.gitignore` file to exclude them from the version control you're using.
With this, we avoid having a double aside here, adding yet another break point in the documentation and make the issue more discoverable as you can see below:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jonniebigodes Thank you so much for your feedback. :)
I saw your feedback and reflected it exactly.
I would appreciate it if you could check my PR one more time.
@turtle601, no need to thank you whatsoever, glad to help you! I appreciate you addressing the feedback so quickly. I've checked, and all is good on my end. I'm going to merge this once the checklist clears. Hope you have a fantastic day. |
Closes #25987
What I did
'yarn storybook' creates node_modules/.cache in Yarn 2 PnP project
I think the development environment can cause confusion for those developing in pnp mode.
so, i add 'yarn storybook' creates node_modules/.cache in Yarn 2 PnP project in get-started/install.md files
Checklist for Contributors
Testing
The changes in this PR are covered in the following automated tests:
Manual testing
This section is mandatory for all contributions. If you believe no manual test is necessary, please state so explicitly. Thanks!
Documentation
MIGRATION.MD
Checklist for Maintainers
When this PR is ready for testing, make sure to add
ci:normal
,ci:merged
orci:daily
GH label to it to run a specific set of sandboxes. The particular set of sandboxes can be found incode/lib/cli/src/sandbox-templates.ts
Make sure this PR contains one of the labels below:
Available labels
bug
: Internal changes that fixes incorrect behavior.maintenance
: User-facing maintenance tasks.dependencies
: Upgrading (sometimes downgrading) dependencies.build
: Internal-facing build tooling & test updates. Will not show up in release changelog.cleanup
: Minor cleanup style change. Will not show up in release changelog.documentation
: Documentation only changes. Will not show up in release changelog.feature request
: Introducing a new feature.BREAKING CHANGE
: Changes that break compatibility in some way with current major version.other
: Changes that don't fit in the above categories.🦋 Canary release
This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the
@storybookjs/core
team here.core team members can create a canary release here or locally with
gh workflow run --repo storybookjs/storybook canary-release-pr.yml --field pr=<PR_NUMBER>