-
Notifications
You must be signed in to change notification settings - Fork 5
chore(295): add support for mdx stories #298
Conversation
Adds support for the newer mdx story format
Codecov Report
@@ Coverage Diff @@
## master #298 +/- ##
=======================================
Coverage 47.31% 47.31%
=======================================
Files 143 143
Lines 2012 2012
Branches 362 362
=======================================
Hits 952 952
Misses 1010 1010
Partials 50 50
Continue to review full report at Codecov.
|
Saw this PR and wanted to see if we can get "controls" (or "essentials") added while we're at it? Might need to update Also I'd like to help test this out, but can't figure out how to point to the commit, updating the package.json to use |
"@storybook/react": "6.1.20", | ||
"@storybook/theming": "6.1.20", | ||
"@storybook/addon-actions": "6.2.7", | ||
"@storybook/addon-backgrounds": "6.2.7", |
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.
Shoot, should have removed the old addons and added essentials here
"@storybook/theming": "6.1.20", | ||
"@storybook/addon-a11y": "6.2.7", | ||
"@storybook/addon-docs": "6.2.7", | ||
"@storybook/addon-essentials": "6.2.7", |
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.
This replaces a bunch of individual addons
], | ||
stories: [process.cwd() + "/**/*.stories.[tj]s[x]"], | ||
stories: [process.cwd() + "/**/*.stories.@(js|ts|jsx|tsx|mdx)"], |
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.
This is the new recommended format from storybook
@@ -340,7 +340,7 @@ export function getSetup(options: Options) { | |||
"@src": resolveSourceRoot(), | |||
}, | |||
extensions: [".js", ".json", ".jsx", ".mjs", ".ts", ".tsx"], | |||
modules: [resolveSourceRoot(), "node_modules"], | |||
modules: [resolveSourceRoot(), "node_modules", "stories"], |
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.
gotta resolve stories, I'm not 100% sure why, just following instructions.
@twilliams15 ok things should be good to go. Instructions for testing
|
@@ -29,6 +29,7 @@ | |||
"@pixeloven/cli": "^7.0.0-alpha.0", | |||
"@pixeloven/cli-addon-storybook": "^7.0.0-alpha.1", | |||
"@pixeloven/cli-core": "^7.0.0-alpha.0", | |||
"@storybook/addon-docs": "6.2.7", |
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.
@jimmynotjim This was one of the reason I had the common library so we can wrap dependencies like this.
Adds support for the newer mdx story format