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

Export StoryContext type from Storybook core #9726

Open
ArrayKnight opened this issue Feb 3, 2020 · 3 comments
Open

Export StoryContext type from Storybook core #9726

ArrayKnight opened this issue Feb 3, 2020 · 3 comments

Comments

@ArrayKnight
Copy link

ArrayKnight commented Feb 3, 2020

Is your feature request related to a problem? Please describe.
Currently, if you're running a project in Typescript and you need to add the StoryContext type to the story function, you have to import it from @storybook/addons. This feels like a weird dependency considering the project might not be using any addons.

export const MyStory = (context: StoryContext) => <MyComponent />

Describe the solution you'd like

import { StoryContext } from '@storybook/[framework]'

Are you able to assist bring the feature to reality?
No

@shilman
Copy link
Member

shilman commented Feb 4, 2020

Thanks @ArrayKnight. We had a types PR to @storybook/csf repo. I hope to clean that up and make it official.

@stale
Copy link

stale bot commented Feb 27, 2020

Hi everyone! Seems like there hasn't been much going on in this issue lately. If there are still questions, comments, or bugs, please feel free to continue the discussion. Unfortunately, we don't have time to get to every issue. We are always open to contributions so please send us a pull request if you would like to help. Inactive issues will be closed after 30 days. Thanks!

@stale stale bot added the inactive label Feb 27, 2020
@stale stale bot removed the inactive label Feb 28, 2020
@shilman
Copy link
Member

shilman commented May 21, 2020

We've just released zero-config typescript support in 6.0-beta. Please upgrade and test it!

Thanks for your help and support getting this stable for release!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants