Addon-Docs: Configurable Source snippetization
See original GitHub issueAdd the ability to configure Source block with per-framework snippetization, or even user-configurable snippetization. E.g.
- @CodeByAlex wants just the
template:
field for Angular etb
(?) wants to remove the() => ...
HamHam
wants to remove single quotes from:
<Story name="heading" height="100px">
{'<h1>Hello World</h1>'}
</Story>
- @kushalmahajan wants to include the component’s source in the story #10039
Issue Analytics
- State:
- Created 4 years ago
- Reactions:22
- Comments:23 (12 by maintainers)
Top Results From Across the Web
Docs Addon | Storybook: Frontend workshop for UI development
DocsPage pulls information from your stories, components, source code, ... The addon-docs preset has a few configuration options that can be used to ......
Read more >@storybook/addon-interactions: Versions | Openbase
Addon-docs : Fix React Profiler in source snippets #19004 ... Add a TypeScript check task and configure ci to run it #19471; Add...
Read more >@storybook/addon-docs | Yarn - Package Manager
Storybook Docs · DocsPage · MDX · Framework support · Installation · Preset options · Manual configuration · TypeScript configuration · More resources....
Read more >Top 5 @storybook/addon-docs Code Examples - Snyk
Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues...
Read more >Custom documentation pages for storybookjs - Atanas Stoyanov
The Storybook addon-docs is a great feature to display documentation in… ... in .storybook/main.js — enable the plugin and configure the pages options ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You can use
mdxSource
on<Preview>
as a temporary override. Not ideal, but provides the expected highlighted source code:Full example
</div>Warning: adding multiple
<Story>
components inside<Preview>
causes issue https://github.com/storybookjs/storybook/issues/6738#issuecomment-575369564 on my end¡Ay Caramba!! I just released https://github.com/storybookjs/storybook/releases/tag/v6.0.0-alpha.28 containing PR #10184 that references this issue. Upgrade today to try it out!
You can find this prerelease on the
@next
NPM tag.