From 07da81da2f44714c79930e93a00bd5ad321fe49c Mon Sep 17 00:00:00 2001 From: Kyle Gach Date: Mon, 6 May 2024 17:06:12 -0600 Subject: [PATCH] Merge pull request #27042 from storybookjs/docs-mdx-gfm-link Docs: Fix bad link for MDX remark-gfm (cherry picked from commit cbadd7403f2091444bb00d597820bc960971f8c6) --- code/addons/gfm/src/index.ts | 2 +- code/lib/cli/src/automigrate/fixes/mdx-gfm.ts | 2 +- docs/essentials/index.md | 20 +++++++++---------- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/code/addons/gfm/src/index.ts b/code/addons/gfm/src/index.ts index c23a1036d5d..0cadb00aeb4 100644 --- a/code/addons/gfm/src/index.ts +++ b/code/addons/gfm/src/index.ts @@ -12,7 +12,7 @@ export const mdxLoaderOptions = async (config: any) => { deprecate(dedent` The "@storybook/addon-mdx-gfm" addon is meant as a migration assistant for Storybook 8.0; and will likely be removed in a future version. It's recommended you read this document: - https://storybook.js.org/docs/react/writing-docs/mdx#lack-of-github-flavored-markdown-gfm + https://storybook.js.org/docs/writing-docs/mdx#markdown-tables-arent-rendering-correctly Once you've made the necessary changes, you can remove the addon from your package.json and storybook config. `); diff --git a/code/lib/cli/src/automigrate/fixes/mdx-gfm.ts b/code/lib/cli/src/automigrate/fixes/mdx-gfm.ts index 98bcaa736b8..3ff99f5c2fb 100644 --- a/code/lib/cli/src/automigrate/fixes/mdx-gfm.ts +++ b/code/lib/cli/src/automigrate/fixes/mdx-gfm.ts @@ -82,7 +82,7 @@ export const mdxgfm: Fix = { Storybook >= 8.0 uses MDX3 for compiling MDX, and thus no longer supports GFM out of the box. Because of this you need to explicitly add the GFM plugin in the addon-docs options: - https://storybook.js.org/docs/react/writing-docs/mdx#lack-of-github-flavored-markdown-gfm + https://storybook.js.org/docs/writing-docs/mdx#markdown-tables-arent-rendering-correctly We recommend that you follow the guide in the link above; however, we can add a temporary Storybook addon to help make this migration easier. We'll install the addon and add it to your storybook config. diff --git a/docs/essentials/index.md b/docs/essentials/index.md index 2ef9254bfab..15414870764 100644 --- a/docs/essentials/index.md +++ b/docs/essentials/index.md @@ -87,16 +87,16 @@ Below is an abridged configuration and table with all the available options for -| Addon | Option | Description | -| ------------------------------ | ------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `@storybook/addon-actions` | N/A | N/A | -| `@storybook/addon-viewport` | N/A | N/A | -| `@storybook/addon-docs` | `csfPluginOptions` | Provides additional configuration for Storybook's CSF plugin. Can be disabled with `null`. | -| | `mdxPluginOptions` | Provides additional configuration options and plugin configuration for [MDX documentation](../writing-docs/mdx.md#lack-of-github-flavored-markdown-gfm). | -| `@storybook/addon-controls` | N/A | N/A | -| `@storybook/addon-backgrounds` | N/A | N/A | -| `@storybook/addon-toolbars` | N/A | N/A | -| `@storybook/addon-measure` | N/A | N/A | +| Addon | Option | Description | +| ------------------------------ | ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `@storybook/addon-actions` | N/A | N/A | +| `@storybook/addon-viewport` | N/A | N/A | +| `@storybook/addon-docs` | `csfPluginOptions` | Provides additional configuration for Storybook's CSF plugin. Can be disabled with `null`. | +| | `mdxPluginOptions` | Provides additional configuration options and plugin configuration for [MDX documentation](../writing-docs/mdx.md#markdown-tables-arent-rendering-correctly). | +| `@storybook/addon-controls` | N/A | N/A | +| `@storybook/addon-backgrounds` | N/A | N/A | +| `@storybook/addon-toolbars` | N/A | N/A | +| `@storybook/addon-measure` | N/A | N/A | When you start Storybook, your custom configuration will override the default.