Skip to content

Remove all references to @mdx-js/react #80870

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

Open
wants to merge 1 commit into
base: canary
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion crates/next-core/src/next_import_map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -857,7 +857,6 @@ async fn insert_next_shared_aliases(
vec![
request_to_import_mapping(project_path, "./mdx-components"),
request_to_import_mapping(project_path, "./src/mdx-components"),
request_to_import_mapping(project_path, "@mdx-js/react"),
request_to_import_mapping(project_path, "@next/mdx/mdx-components.js"),
],
);
Expand Down
2 changes: 1 addition & 1 deletion docs/01-app/02-guides/mdx.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ The `@next/mdx` package, and related packages, are used to configure Next.js so
Install these packages to render MDX with Next.js:

```bash filename="Terminal"
npm install @next/mdx @mdx-js/loader @mdx-js/react @types/mdx
npm install @next/mdx @mdx-js/loader @types/mdx
```

## Configure `next.config.mjs`
Expand Down
3 changes: 1 addition & 2 deletions examples/mdx-pages/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@
"start": "next start"
},
"dependencies": {
"@mdx-js/loader": "^1.5.1",
"@mdx-js/react": "^1.6.18",
"@mdx-js/loader": "^3.1.0",
"@next/mdx": "^9.1.1",
"next": "latest",
"react": "^18.2.0",
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@
"@fullhuman/postcss-purgecss": "1.3.0",
"@jest/expect-utils": "29.7.0",
"@mdx-js/loader": "2.2.1",
"@mdx-js/react": "2.2.1",
"@next/bundle-analyzer": "workspace:*",
"@next/env": "workspace:*",
"@next/eslint-plugin-next": "workspace:*",
Expand Down
1 change: 0 additions & 1 deletion packages/next-mdx/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ module.exports =
config.resolve.alias['next-mdx-import-source-file'] = [
'private-next-root-dir/src/mdx-components',
'private-next-root-dir/mdx-components',
'@mdx-js/react',
require.resolve('./mdx-components.js'),
]
config.module.rules.push({
Expand Down
6 changes: 1 addition & 5 deletions packages/next-mdx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,11 @@
"directory": "packages/next-mdx"
},
"peerDependencies": {
"@mdx-js/loader": ">=0.15.0",
"@mdx-js/react": ">=0.15.0"
"@mdx-js/loader": ">=0.15.0"
},
"peerDependenciesMeta": {
"@mdx-js/loader": {
"optional": true
},
"@mdx-js/react": {
"optional": true
}
},
"dependencies": {
Expand Down
23 changes: 0 additions & 23 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ describe('ReactRefreshRegression app', () => {
'styled-components': '6.1.16',
'@next/mdx': 'canary',
'@mdx-js/loader': '2.2.1',
'@mdx-js/react': '2.2.1',
},
skipStart: true,
})
Expand Down
1 change: 0 additions & 1 deletion test/development/acceptance-app/app-hmr-changes.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ describe('Error overlay - RSC build errors', () => {
'@next/mdx': 'canary',
'react-wrap-balancer': '^0.2.4',
'react-tweet': '^3.2.0',
'@mdx-js/react': '^2.3.0',
tailwindcss: '^3.2.6',
typescript: 'latest',
'@types/react': '^18.0.28',
Expand Down
1 change: 0 additions & 1 deletion test/development/acceptance/ReactRefreshRegression.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ describe('ReactRefreshRegression', () => {
'styled-components': '6.1.16',
'@next/mdx': 'canary',
'@mdx-js/loader': '2.2.1',
'@mdx-js/react': '2.2.1',
},
})

Expand Down
1 change: 0 additions & 1 deletion test/e2e/app-dir/mdx/mdx.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ for (const type of ['with-mdx-rs', 'without-mdx-rs']) {
dependencies: {
'@next/mdx': 'canary',
'@mdx-js/loader': '^2.2.1',
'@mdx-js/react': '^2.2.1',
'rehype-katex': '7.0.1',
},
env: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ describe('modularizeImports', () => {
dependencies: {
'@next/mdx': 'canary',
'@mdx-js/loader': '^2.2.1',
'@mdx-js/react': '^2.2.1',
},
})

Expand Down
Loading