mirror of
https://github.com/mdx-js/mdx.git
synced 2024-08-16 18:30:27 +03:00
3.0.0
This commit is contained in:
parent
78a1eb5202
commit
9a40e181db
@ -47,27 +47,14 @@ This makes writing long-form content with components a blast. {/* more */}
|
|||||||
[Continue reading »][what]
|
[Continue reading »][what]
|
||||||
|
|
||||||
<div className="card big">
|
<div className="card big">
|
||||||
## New: MDX 2!
|
## New: MDX 3!
|
||||||
|
|
||||||
Version 2 of MDX was released after years of hard work, and has many
|
A small major this time, nothing big, which is also nice sometimes!
|
||||||
improvements.
|
This mainly drops support for old Node (use 16 or later), adds modern ES2024
|
||||||
Here are the highlights:
|
support in MDX, supports `await` in MDX (if your framework does too), and
|
||||||
|
removes several deprecated options.
|
||||||
|
|
||||||
<div className="emoji-list">
|
[Continue reading »][v3]
|
||||||
* 📝 **Improved syntax** makes it easier to use markdown in JSX
|
|
||||||
* 🧑💻 **JavaScript expressions** turn `{2 * Math.PI}` into {2 * Math.PI}
|
|
||||||
* 🔌 New **esbuild**, **Rollup**, and **Node.js** integrations
|
|
||||||
* ⚛️ **Any JSX runtime**: React, Preact, Vue, Emotion, you name it, they’re
|
|
||||||
all supported
|
|
||||||
* 🌳 **Improved AST** exposes more info in greater detail
|
|
||||||
* 🏃♀️ Compiles at least **25% faster**
|
|
||||||
* 🚴 Generated code runs twice as fast (**100% faster**)
|
|
||||||
* 🚄 Bundle size of `@mdx-js/mdx` is more than three times as small
|
|
||||||
(**250% smaller**)
|
|
||||||
* 🧵 …and much, so much more
|
|
||||||
</div>
|
|
||||||
|
|
||||||
[Continue reading »][v2]
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
## What does MDX do?
|
## What does MDX do?
|
||||||
@ -145,7 +132,7 @@ You’re using React, Preact, or Vue.
|
|||||||
|
|
||||||
[what]: /docs/what-is-mdx/
|
[what]: /docs/what-is-mdx/
|
||||||
|
|
||||||
[v2]: /blog/v2/
|
[v3]: /blog/v3/
|
||||||
|
|
||||||
[playground]: /playground/
|
[playground]: /playground/
|
||||||
|
|
||||||
|
34
package-lock.json
generated
34
package-lock.json
generated
@ -3973,9 +3973,9 @@
|
|||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"node_modules/electron-to-chromium": {
|
"node_modules/electron-to-chromium": {
|
||||||
"version": "1.4.565",
|
"version": "1.4.566",
|
||||||
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.565.tgz",
|
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.566.tgz",
|
||||||
"integrity": "sha512-XbMoT6yIvg2xzcbs5hCADi0dXBh4//En3oFXmtPX+jiyyiCTiM9DGFT2SLottjpEs9Z8Mh8SqahbR96MaHfuSg=="
|
"integrity": "sha512-mv+fAy27uOmTVlUULy15U3DVJ+jg+8iyKH1bpwboCRhtDC69GKf1PPTZvEIhCyDr81RFqfxZJYrbgp933a1vtg=="
|
||||||
},
|
},
|
||||||
"node_modules/emoji-regex": {
|
"node_modules/emoji-regex": {
|
||||||
"version": "9.2.2",
|
"version": "9.2.2",
|
||||||
@ -28608,10 +28608,10 @@
|
|||||||
},
|
},
|
||||||
"packages/esbuild": {
|
"packages/esbuild": {
|
||||||
"name": "@mdx-js/esbuild",
|
"name": "@mdx-js/esbuild",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdx-js/mdx": "^2.0.0",
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
"@types/unist": "^3.0.0",
|
"@types/unist": "^3.0.0",
|
||||||
"vfile": "^6.0.0",
|
"vfile": "^6.0.0",
|
||||||
"vfile-message": "^4.0.0"
|
"vfile-message": "^4.0.0"
|
||||||
@ -28626,10 +28626,10 @@
|
|||||||
},
|
},
|
||||||
"packages/loader": {
|
"packages/loader": {
|
||||||
"name": "@mdx-js/loader",
|
"name": "@mdx-js/loader",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdx-js/mdx": "^2.0.0",
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
"source-map": "^0.7.0"
|
"source-map": "^0.7.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {},
|
"devDependencies": {},
|
||||||
@ -28643,7 +28643,7 @@
|
|||||||
},
|
},
|
||||||
"packages/mdx": {
|
"packages/mdx": {
|
||||||
"name": "@mdx-js/mdx",
|
"name": "@mdx-js/mdx",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/estree": "^1.0.0",
|
"@types/estree": "^1.0.0",
|
||||||
@ -28660,7 +28660,7 @@
|
|||||||
"hast-util-to-jsx-runtime": "^2.0.0",
|
"hast-util-to-jsx-runtime": "^2.0.0",
|
||||||
"markdown-extensions": "^2.0.0",
|
"markdown-extensions": "^2.0.0",
|
||||||
"periscopic": "^3.0.0",
|
"periscopic": "^3.0.0",
|
||||||
"remark-mdx": "^2.0.0",
|
"remark-mdx": "^3.0.0",
|
||||||
"remark-parse": "^11.0.0",
|
"remark-parse": "^11.0.0",
|
||||||
"remark-rehype": "^11.0.0",
|
"remark-rehype": "^11.0.0",
|
||||||
"source-map": "^0.7.0",
|
"source-map": "^0.7.0",
|
||||||
@ -28685,10 +28685,10 @@
|
|||||||
},
|
},
|
||||||
"packages/node-loader": {
|
"packages/node-loader": {
|
||||||
"name": "@mdx-js/node-loader",
|
"name": "@mdx-js/node-loader",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdx-js/mdx": "^2.0.0",
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
"vfile": "^6.0.0"
|
"vfile": "^6.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {},
|
"devDependencies": {},
|
||||||
@ -28699,7 +28699,7 @@
|
|||||||
},
|
},
|
||||||
"packages/preact": {
|
"packages/preact": {
|
||||||
"name": "@mdx-js/preact",
|
"name": "@mdx-js/preact",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/mdx": "^2.0.0"
|
"@types/mdx": "^2.0.0"
|
||||||
@ -28715,7 +28715,7 @@
|
|||||||
},
|
},
|
||||||
"packages/react": {
|
"packages/react": {
|
||||||
"name": "@mdx-js/react",
|
"name": "@mdx-js/react",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/mdx": "^2.0.0"
|
"@types/mdx": "^2.0.0"
|
||||||
@ -28731,7 +28731,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"packages/remark-mdx": {
|
"packages/remark-mdx": {
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"mdast-util-mdx": "^3.0.0",
|
"mdast-util-mdx": "^3.0.0",
|
||||||
@ -28745,10 +28745,10 @@
|
|||||||
},
|
},
|
||||||
"packages/rollup": {
|
"packages/rollup": {
|
||||||
"name": "@mdx-js/rollup",
|
"name": "@mdx-js/rollup",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdx-js/mdx": "^2.0.0",
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
"@rollup/pluginutils": "^5.0.0",
|
"@rollup/pluginutils": "^5.0.0",
|
||||||
"source-map": "^0.7.0",
|
"source-map": "^0.7.0",
|
||||||
"vfile": "^6.0.0"
|
"vfile": "^6.0.0"
|
||||||
@ -28764,7 +28764,7 @@
|
|||||||
},
|
},
|
||||||
"packages/vue": {
|
"packages/vue": {
|
||||||
"name": "@mdx-js/vue",
|
"name": "@mdx-js/vue",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@types/mdx": "^2.0.0"
|
"@types/mdx": "^2.0.0"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdx-js/esbuild",
|
"name": "@mdx-js/esbuild",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "esbuild plugin for MDX",
|
"description": "esbuild plugin for MDX",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
@ -37,7 +37,7 @@
|
|||||||
"index.js"
|
"index.js"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdx-js/mdx": "^2.0.0",
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
"@types/unist": "^3.0.0",
|
"@types/unist": "^3.0.0",
|
||||||
"vfile": "^6.0.0",
|
"vfile": "^6.0.0",
|
||||||
"vfile-message": "^4.0.0"
|
"vfile-message": "^4.0.0"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdx-js/loader",
|
"name": "@mdx-js/loader",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "Webpack loader for MDX",
|
"description": "Webpack loader for MDX",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
@ -43,7 +43,7 @@
|
|||||||
"index.d.ts"
|
"index.d.ts"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdx-js/mdx": "^2.0.0",
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
"source-map": "^0.7.0"
|
"source-map": "^0.7.0"
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdx-js/mdx",
|
"name": "@mdx-js/mdx",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "MDX compiler",
|
"description": "MDX compiler",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
@ -57,7 +57,7 @@
|
|||||||
"hast-util-to-jsx-runtime": "^2.0.0",
|
"hast-util-to-jsx-runtime": "^2.0.0",
|
||||||
"markdown-extensions": "^2.0.0",
|
"markdown-extensions": "^2.0.0",
|
||||||
"periscopic": "^3.0.0",
|
"periscopic": "^3.0.0",
|
||||||
"remark-mdx": "^2.0.0",
|
"remark-mdx": "^3.0.0",
|
||||||
"remark-parse": "^11.0.0",
|
"remark-parse": "^11.0.0",
|
||||||
"remark-rehype": "^11.0.0",
|
"remark-rehype": "^11.0.0",
|
||||||
"source-map": "^0.7.0",
|
"source-map": "^0.7.0",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdx-js/node-loader",
|
"name": "@mdx-js/node-loader",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "Node.js loader for MDX",
|
"description": "Node.js loader for MDX",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
@ -42,7 +42,7 @@
|
|||||||
"index.js"
|
"index.js"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdx-js/mdx": "^2.0.0",
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
"vfile": "^6.0.0"
|
"vfile": "^6.0.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {},
|
"devDependencies": {},
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdx-js/preact",
|
"name": "@mdx-js/preact",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "Preact context for MDX",
|
"description": "Preact context for MDX",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdx-js/react",
|
"name": "@mdx-js/react",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "React context for MDX",
|
"description": "React context for MDX",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "remark-mdx",
|
"name": "remark-mdx",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "remark plugin to support MDX syntax",
|
"description": "remark plugin to support MDX syntax",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdx-js/rollup",
|
"name": "@mdx-js/rollup",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "Rollup plugin for MDX",
|
"description": "Rollup plugin for MDX",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
@ -37,7 +37,7 @@
|
|||||||
"index.js"
|
"index.js"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdx-js/mdx": "^2.0.0",
|
"@mdx-js/mdx": "^3.0.0",
|
||||||
"@rollup/pluginutils": "^5.0.0",
|
"@rollup/pluginutils": "^5.0.0",
|
||||||
"source-map": "^0.7.0",
|
"source-map": "^0.7.0",
|
||||||
"vfile": "^6.0.0"
|
"vfile": "^6.0.0"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdx-js/vue",
|
"name": "@mdx-js/vue",
|
||||||
"version": "2.3.0",
|
"version": "3.0.0",
|
||||||
"description": "Vue provider for MDX",
|
"description": "Vue provider for MDX",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
Loading…
Reference in New Issue
Block a user