-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Feat : Add codesandbox storybook addon #4602
base: 3.x
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## 3.x #4602 +/- ##
==========================================
+ Coverage 95.73% 95.99% +0.25%
==========================================
Files 119 123 +4
Lines 22699 23460 +761
Branches 3130 3172 +42
==========================================
+ Hits 21731 22520 +789
+ Misses 962 934 -28
Partials 6 6 ☔ View full report in Codecov by Sentry. |
@@ -22,6 +22,14 @@ const preview: Preview = { | |||
}, | |||
// Sets a delay of 1550ms before each story to give them time to animate (recharts animation default is 1500ms) | |||
chromatic: { delay: 1550 }, | |||
codesandbox: { | |||
apiToken: '', |
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.
So I would like to use this addon but I can't see how to get this token through. It's private so we cannot just embed it in the source code. Thoughts?
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.
I changed you to Admin in codesandbox - go to recharts -> settings -> permissions -> API Access
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.
But I agree, there's no great way to use the API token. Env variables aren't safe still even if we did it in CI
codesandbox/storybook-addon#17 might resolve once we finish refactoring but idk |
Description
Added the storybook addon provided by codesandbox.
Related Issue
Not all issues have been resolved yet.
This is an issue related to environment variables, and more details can be found in the comments on the issue.
You need to add environment variables related to apiToken in the
storybook/preview.ts
file.Motivation and Context
By automating the creation of codesandbox links, users can more easily test the UI and bug fix.
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist: