-
-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
Chore add workflows snippets for 6.0 docs #11872
Conversation
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.
Looks good, I wonder about the TS snippets. I suppose depending on your TS settings you may or may not have to type your stories--is this right @shilman / @jonniebigodes?
What do we want to do in our snippets?
|
||
import MyComponentThatHasAQuery, { MyQuery} from '../component-that-has-a-query'; | ||
|
||
export const LoggedOut = () => <MyComponentThatHasAQuery />; |
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.
Let's use a template.
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.
Changed the snippet to include a template with the latest commit.
Let me know if you need anything else.
import { ListItem, ListItemProps} from './ListItem'; | ||
import { Unchecked } from './ListItem.stories'; | ||
|
||
const ListTemplate = ({ items, ...args }) => ( |
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.
Do we need types here?
@tmeasday @jonniebigodes i don't really understand the different levels of type strictness in TS. i think given that a lot of TS people like their types strict, we should do our best to provide strictly typed TS snippets. people who want to be loose are welcome to omit whatever their settings allow them to. |
@shilman exactly why i did it here. Also as a added bonus, involuntarily we're adding good practices. |
Now is using a template
conflicts are solved, let me know if you need anything else. |
This pull request adds the code snippets for the workflows section.
What was done:
Feel free to provide feedback