-
Notifications
You must be signed in to change notification settings - Fork 85
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
Add Storybook boilerplate to design-system
package
#1660
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
github-actions
bot
added
area/apps > hash*
Affects HASH (a `hash-*` app)
area/deps
Relates to third-party dependencies (area)
labels
Dec 13, 2022
github-actions
bot
added
the
area/infra
Relates to version control, CI, CD or IaC (area)
label
Dec 13, 2022
kachkaev
changed the title
Add Storybook for
Add Storybook to Dec 13, 2022
design-system
packagedesign-system
package
kachkaev
changed the title
Add Storybook to
Add Storybook boilerplate to Dec 13, 2022
design-system
packagedesign-system
package
kachkaev
requested review from
benwerner01,
CiaranMn,
luisbettencourt,
nathggns and
yusufkinatas
December 13, 2022 22:43
CiaranMn
approved these changes
Dec 16, 2022
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area/apps > hash*
Affects HASH (a `hash-*` app)
area/deps
Relates to third-party dependencies (area)
area/infra
Relates to version control, CI, CD or IaC (area)
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🌟 What is the purpose of this PR?
This PR initializes Storybook in
/packages/hash/design-system
. Once Storybook boilerplate is merged, we can configure its deployment and proceed to writing initial user stories. Boilerplate content is pretty lightweight so we won’t lose much from having it inmain
for a short while. This boilerplate can work as a handy reference in the future.🔗 Related links
📜 Does this require a change to the docs?
Not yet
The current stable version of Storybook is v6. It has issues with MDX pages when React 18 is used: MDX Docs doesn't display after upgrades to React v18.1.0 + Storybook v6.5.6 -> v6.5.7 -> v6.5.8 -> v6.5.9 storybookjs/storybook#18383. To avoid this, I have upgraded to v7 beta which comes with MDX2 and has a few more improvements (
satisfies
operator, new API for stories etc. The versions of Storybook packages are pinned inyarn.lock
so we can chose when to upgrade to another beta or a stable version. The boilerplate for v6 looks a bit different to what I’ve seen in v7, so I suggest that we start with v7 straight away and save ourselves time on migrating. Using beta carries a bit of risk, but it’s not worse than not being able to use MDX in v6.I had to manually create
babel.config.json
to avoid syntax errors in v7. Could be an issue with the init command or default parser config.🐾 Next steps
🛡 What tests cover this?
❓ How to test this?
📹 Demo