Conversation
Introduces documentation for the `grid` module using storybook's `addon-docs` package. This allows these docs to appear within storybook and take advantage of features like MDX (markdown with JSX), and the included doc blocks such as `Source`. This change requires enabling the docs addon within storybook's `addon-essentials` package. It also means setting up aliases for `react` and `react-dom`, as adding the docs addon without this resulted in dependency resolution errors across the codebase: ``` Module not found: Error: Can't resolve 'react' in [...] ```
|
Hello 👋! When you're ready to run Chromatic, please apply the You will need to reapply the label each time you want to run Chromatic. |
| react: 'react', | ||
| 'react-dom': 'react-dom', |
There was a problem hiding this comment.
Without this, just setting up the docs addon with no other changes resulted in dependency resolution errors across the codebase:
Module not found: Error: Can't resolve 'react' in [...]
where [...] represents any file where react is imported.
arelra
left a comment
There was a problem hiding this comment.
Thank you for creating such detailed and understandable documentation!
I wonder if it's worth adding an MDX viewer to the list of recommended VS Code extensions, so such docs can be read outside of Storybook.
marjisound
left a comment
There was a problem hiding this comment.
Thanks for doing this 👏
|
Seen on PROD (merged by @JamieB-gu 9 minutes and 6 seconds ago) Please check your changes! |
Introduces documentation for the
gridmodule using storybook'saddon-docspackage. This allows these docs to appear within storybook and take advantage of features like MDX (markdown with JSX), and the included doc blocks such asSource.The resulting built docs can be seen in the published storybook for this branch.
This change requires enabling the docs addon within storybook's
addon-essentialspackage. It also means setting up aliases forreactandreact-dom, as adding the docs addon without this resulted in dependency resolution errors across the codebase: