v0.2.0
@blocz/mdx-live
- Upgrade for MDX 2 BREAKING CHANGE
- Switch to ESM only (it depends on
@mdx-js/mdx
that also switched to ESM only) BREAKING CHANGE - Add
exports
field inpackage.json
- Add peer dependency on
@mdx-js/mdx
BREAKING CHANGE - Add support for
recmaPlugins
in addition torehypePlugins
andremarkPlugins
inMDX
props useMDX
can accept all kind of plugins- Add
isReady
inuseMDX
return object - Bundle size was reduced from 1.6 MB to 21.9 kB (-98.6%)
@blocz/mdx-plugin-detect-imports
-
Update for MDX 2 (but still in CJS, and compatible in ESM) BREAKING CHANGE
-
Add
exports
field inpackage.json
-
Can only be used in MDX async function (like
compile
) but not the sync ones (likecompileSync
) BREAKING CHANGE -
Change format of
ImportStatement
to better represent named vs default exports: (BREAKING CHANGE)In v0.1.0:
interface ImportStatement { module: string; imports: Array<{ imported: string; local: string; value: any; }>; }
Now in v0.2.0:
interface ImportStatement { module: string; imports: Array< | { kind: "named"; imported: string; local: string; value: any; } | { kind: "namespace" | "default"; local: string; value: any; } >; }
@blocz/detect-imports
Removed because no longer needed
@blocz/mdx-loader
Removed because already fully covered by the recommended @mdx-js/loader
+ @blocz/mdx-plugin-detect-imports
plugin
Other changes
- Upgraded to yarn v3.2.1
- Add support for node 18 in addition to node 16
- Add a few e2e tests
Full changelog: v0.1.0...v0.2.0