Skip to content
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

Docs: Remove babel-loader and @babel/core peer deps #14689

Merged
merged 1 commit into from
Apr 22, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 4 additions & 3 deletions addons/docs/README.md
Expand Up @@ -103,10 +103,10 @@ First add the package. Make sure that the versions for your `@storybook/*` packa
yarn add -D @storybook/addon-docs
```

Docs has peer dependencies on `react` and `babel-loader`. If you want to write stories in MDX, you may need to add these dependencies as well:
Docs has peer dependencies on `react`. If you want to write stories in MDX, you may need to add this dependency as well:

```sh
yarn add -D react babel-loader
yarn add -D react
```

Then add the following to your `.storybook/main.js`:
Expand Down Expand Up @@ -183,7 +183,8 @@ module.exports = {
test: /\.(stories|story)\.mdx$/,
use: [
{
loader: 'babel-loader',
// Need to add babel-loader as dependency: `yarn add -D babel-loader`
loader: require.resolve('babel-loader'),
// may or may not need this line depending on your app's setup
options: {
plugins: ['@babel/plugin-transform-react-jsx'],
Expand Down
4 changes: 2 additions & 2 deletions addons/docs/angular/README.md
Expand Up @@ -96,10 +96,10 @@ storiesOf('App Component', module)

[MDX](../docs/mdx.md) is a convenient way to document your components in Markdown and embed documentation components, such as stories and props tables, inline.

Docs has peer dependencies on `react` and `babel-loader`. If you want to write stories in MDX, you'll need to add these dependencies as well:
Docs has peer dependencies on `react`. If you want to write stories in MDX, you may need to add this dependency as well:

```sh
yarn add -D react babel-loader
yarn add -D react
```

Then update your `.storybook/main.js` to make sure you load MDX files:
Expand Down
4 changes: 2 additions & 2 deletions addons/docs/common/README.md
Expand Up @@ -34,10 +34,10 @@ When you [install docs](#installation) you should get basic [DocsPage](../docs/d

[MDX](../docs/mdx.md) is a convenient way to document your components in Markdown and embed documentation components, such as stories and props tables, inline.

Docs has peer dependencies on `react` and `babel-loader`. If you want to write stories in MDX, you'll need to add these dependencies as well:
Docs has peer dependencies on `react`. If you want to write stories in MDX, you may need to add this dependency as well:

```sh
yarn add -D react babel-loader
yarn add -D react
```

Then update your `.storybook/main.js` to make sure you load MDX files:
Expand Down
4 changes: 2 additions & 2 deletions addons/docs/ember/README.md
Expand Up @@ -78,10 +78,10 @@ storiesOf('App Component', module)

[MDX](../docs/mdx.md) is a convenient way to document your components in Markdown and embed documentation components, such as stories and props tables, inline.

Docs has peer dependencies on `react` and `babel-loader`. If you want to write stories in MDX, you'll need to add these dependencies as well:
Docs has peer dependencies on `react`. If you want to write stories in MDX, you may need to add this dependency as well:

```sh
yarn add -D react babel-loader
yarn add -D react
```

Then update your `.storybook/main.js` to make sure you load MDX files:
Expand Down
2 changes: 0 additions & 2 deletions addons/docs/package.json
Expand Up @@ -134,12 +134,10 @@
"zone.js": "^0.11.3"
},
"peerDependencies": {
"@babel/core": "^7.11.5",
"@storybook/angular": "6.3.0-alpha.13",
"@storybook/vue": "6.3.0-alpha.13",
"@storybook/vue3": "6.3.0-alpha.13",
"@storybook/web-components": "6.3.0-alpha.13",
"babel-loader": "^8.0.0",
"lit-html": "^1.0.0",
"react": "^16.8.0 || ^17.0.0",
"react-dom": "^16.8.0 || ^17.0.0",
Expand Down
6 changes: 0 additions & 6 deletions addons/docs/react/README.md
Expand Up @@ -67,12 +67,6 @@ storiesOf('InfoButton', module)

[MDX](../docs/mdx.md) is a convenient way to document your components in Markdown and embed documentation components, such as stories and props tables, inline.

Docs has peer dependencies on `react` and `babel-loader`. If you want to write stories in MDX, you may need to add these dependencies as well:

```sh
yarn add -D react babel-loader
```

Then update your `.storybook/main.js` to make sure you load MDX files:

```js
Expand Down
4 changes: 2 additions & 2 deletions addons/docs/vue/README.md
Expand Up @@ -93,10 +93,10 @@ storiesOf('InfoButton', module)

[MDX](../docs/mdx.md) is a convenient way to document your components in Markdown and embed documentation components, such as stories and props tables, inline.

Docs has peer dependencies on `react` and `babel-loader`. If you want to write stories in MDX, you'll need to add these dependencies as well:
Docs has peer dependencies on `react`. If you want to write stories in MDX, you may need to add this dependency as well:

```sh
yarn add -D react babel-loader
yarn add -D react
```

Then update your `.storybook/main.js` to make sure you load MDX files:
Expand Down
4 changes: 2 additions & 2 deletions addons/docs/vue3/README.md
Expand Up @@ -93,10 +93,10 @@ storiesOf('InfoButton', module)

[MDX](../docs/mdx.md) is a convenient way to document your components in Markdown and embed documentation components, such as stories and props tables, inline.

Docs has peer dependencies on `react` and `babel-loader`. If you want to write stories in MDX, you'll need to add these dependencies as well:
Docs has peer dependencies on `react`. If you want to write stories in MDX, you may need to add this dependency as well:

```sh
yarn add -D react babel-loader
yarn add -D react
```

Then update your `.storybook/main.js` to make sure you load MDX files:
Expand Down
2 changes: 0 additions & 2 deletions yarn.lock
Expand Up @@ -6018,12 +6018,10 @@ __metadata:
webpack: 4
zone.js: ^0.11.3
peerDependencies:
"@babel/core": ^7.11.5
"@storybook/angular": 6.3.0-alpha.13
"@storybook/vue": 6.3.0-alpha.13
"@storybook/vue3": 6.3.0-alpha.13
"@storybook/web-components": 6.3.0-alpha.13
babel-loader: ^8.0.0
lit-html: ^1.0.0
react: ^16.8.0 || ^17.0.0
react-dom: ^16.8.0 || ^17.0.0
Expand Down