stream-mdx 0.0.1 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (73) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/README.md +68 -64
  3. package/dist/core.cjs +0 -1
  4. package/dist/core.d.cts +12 -0
  5. package/dist/core.d.ts +12 -0
  6. package/dist/core.mjs +0 -1
  7. package/dist/index.cjs +0 -1
  8. package/dist/index.mjs +0 -1
  9. package/dist/plugins/base.cjs +24 -0
  10. package/dist/plugins/base.d.cts +1 -0
  11. package/dist/plugins/base.d.ts +1 -0
  12. package/dist/plugins/base.mjs +2 -0
  13. package/dist/plugins/callouts.cjs +24 -0
  14. package/dist/plugins/callouts.d.cts +1 -0
  15. package/dist/plugins/callouts.d.ts +1 -0
  16. package/dist/plugins/callouts.mjs +2 -0
  17. package/dist/plugins/document.cjs +24 -0
  18. package/dist/plugins/document.d.cts +1 -0
  19. package/dist/plugins/document.d.ts +1 -0
  20. package/dist/plugins/document.mjs +2 -0
  21. package/dist/plugins/footnotes.cjs +24 -0
  22. package/dist/plugins/footnotes.d.cts +1 -0
  23. package/dist/plugins/footnotes.d.ts +1 -0
  24. package/dist/plugins/footnotes.mjs +2 -0
  25. package/dist/plugins/html.cjs +24 -0
  26. package/dist/plugins/html.d.cts +1 -0
  27. package/dist/plugins/html.d.ts +1 -0
  28. package/dist/plugins/html.mjs +2 -0
  29. package/dist/plugins/math/renderer.cjs +24 -0
  30. package/dist/plugins/math/renderer.d.cts +1 -0
  31. package/dist/plugins/math/renderer.d.ts +1 -0
  32. package/dist/plugins/math/renderer.mjs +2 -0
  33. package/dist/plugins/math.cjs +24 -0
  34. package/dist/plugins/math.d.cts +1 -0
  35. package/dist/plugins/math.d.ts +1 -0
  36. package/dist/plugins/math.mjs +2 -0
  37. package/dist/plugins/mdx.cjs +24 -0
  38. package/dist/plugins/mdx.d.cts +1 -0
  39. package/dist/plugins/mdx.d.ts +1 -0
  40. package/dist/plugins/mdx.mjs +2 -0
  41. package/dist/plugins/registry.cjs +24 -0
  42. package/dist/plugins/registry.d.cts +1 -0
  43. package/dist/plugins/registry.d.ts +1 -0
  44. package/dist/plugins/registry.mjs +2 -0
  45. package/dist/plugins/tables.cjs +24 -0
  46. package/dist/plugins/tables.d.cts +1 -0
  47. package/dist/plugins/tables.d.ts +1 -0
  48. package/dist/plugins/tables.mjs +2 -0
  49. package/dist/plugins.cjs +0 -1
  50. package/dist/plugins.mjs +0 -1
  51. package/dist/react.cjs +0 -1
  52. package/dist/react.mjs +0 -1
  53. package/dist/worker/mdx-compile.cjs +24 -0
  54. package/dist/worker/mdx-compile.d.cts +1 -0
  55. package/dist/worker/mdx-compile.d.ts +1 -0
  56. package/dist/worker/mdx-compile.mjs +2 -0
  57. package/dist/worker/node.cjs +24 -0
  58. package/dist/worker/node.d.cts +1 -0
  59. package/dist/worker/node.d.ts +1 -0
  60. package/dist/worker/node.mjs +2 -0
  61. package/dist/worker.cjs +0 -1
  62. package/dist/worker.mjs +0 -1
  63. package/package.json +67 -6
  64. package/dist/core.cjs.map +0 -1
  65. package/dist/core.mjs.map +0 -1
  66. package/dist/index.cjs.map +0 -1
  67. package/dist/index.mjs.map +0 -1
  68. package/dist/plugins.cjs.map +0 -1
  69. package/dist/plugins.mjs.map +0 -1
  70. package/dist/react.cjs.map +0 -1
  71. package/dist/react.mjs.map +0 -1
  72. package/dist/worker.cjs.map +0 -1
  73. package/dist/worker.mjs.map +0 -1
package/CHANGELOG.md ADDED
@@ -0,0 +1,36 @@
1
+ # stream-mdx
2
+
3
+ ## 0.0.3
4
+
5
+ ### Patch Changes
6
+
7
+ - 7c79f09: Port the docs demo page to match the ql-homepage streaming UI, and fix several streaming parser/rendering edge cases (hard line breaks and display-math handling) while keeping the hosted worker bundle self-contained for static hosting.
8
+ - Updated dependencies [47d1374]
9
+ - Updated dependencies [7c79f09]
10
+ - @stream-mdx/core@0.0.3
11
+ - @stream-mdx/worker@0.0.3
12
+ - @stream-mdx/react@0.0.3
13
+ - @stream-mdx/plugins@0.0.3
14
+
15
+ ## 0.0.2
16
+
17
+ ### Patch Changes
18
+
19
+ - 9e94660: Docs and release-quality improvements: ship package READMEs/CHANGELOGs, add pack+install smoke tests, expose MDX parity helper entrypoints, and add a deployable docs site workflow.
20
+ - Updated dependencies [9e94660]
21
+ - @stream-mdx/core@0.0.2
22
+ - @stream-mdx/plugins@0.0.2
23
+ - @stream-mdx/worker@0.0.2
24
+ - @stream-mdx/react@0.0.2
25
+
26
+ ## 0.0.1
27
+
28
+ ### Patch Changes
29
+
30
+ - ba64f2c: Add a full README for the `stream-mdx` convenience package and expand the root entrypoint to re-export all public modules.
31
+ - Release maintenance: CI/build fixes, missing runtime deps (e.g. `rehype-katex`), and improved docs/README wiring for the `stream-mdx` package page.
32
+ - Updated dependencies
33
+ - @stream-mdx/core@0.0.1
34
+ - @stream-mdx/plugins@0.0.1
35
+ - @stream-mdx/worker@0.0.1
36
+ - @stream-mdx/react@0.0.1
package/README.md CHANGED
@@ -1,110 +1,114 @@
1
1
  # `stream-mdx`
2
2
 
3
- High-performance streaming Markdown/MDX renderer for React with a worker-first pipeline, incremental patching, and backpressure/guardrails.
3
+ High-performance streaming Markdown/MDX renderer for React with a worker-first pipeline, incremental patching, and backpressure guardrails.
4
4
 
5
5
  This is the **convenience** package:
6
6
 
7
- - `stream-mdx` (root) re-exports the main React API from `@stream-mdx/react`
8
- - `stream-mdx/core`, `stream-mdx/plugins`, `stream-mdx/worker`, `stream-mdx/react` map to the scoped packages
7
+ - `stream-mdx` re-exports the main React API from `@stream-mdx/react`
8
+ - `stream-mdx/{core,react,worker,plugins}` proxy to the scoped packages
9
+ - `stream-mdx/plugins/*` proxies the common plugin entrypoints (helpful for pnpm users)
9
10
 
10
- If you want maximum modularity / tree-shaking control, install the scoped packages directly. Otherwise, start here.
11
+ If you want maximum modularity (or you’re publishing your own library), install the scoped packages directly. Otherwise, start here.
11
12
 
12
- ## Full documentation
13
+ ## Install
13
14
 
14
- The npm README is intentionally a “front page”. The full manual lives in the repo:
15
+ ```bash
16
+ npm install stream-mdx
17
+ ```
15
18
 
16
- - https://github.com/kmccleary3301/stream-mdx/blob/main/docs/COMPREHENSIVE_PROJECT_DOCUMENTATION.md
19
+ ## Quickstart
17
20
 
18
- ## Install
21
+ ### 1) Copy the hosted worker bundle
22
+
23
+ In production you should host the worker bundle from static assets (stricter CSP, no `blob:`).
24
+
25
+ After installing, copy the worker into your app:
19
26
 
20
27
  ```bash
21
- npm install stream-mdx
28
+ mkdir -p public/workers
29
+ cp node_modules/@stream-mdx/worker/dist/hosted/markdown-worker.js public/workers/markdown-worker.js
22
30
  ```
23
31
 
24
- ## Quickstart (Next.js / React)
32
+ ### Next.js (App Router)
25
33
 
26
- `StreamingMarkdown` is a **client component**. Import it from a client file (or add `"use client"` at the top of your component file).
34
+ `StreamingMarkdown` is a **client component**. Import it behind a `"use client"` boundary.
27
35
 
28
36
  ```tsx
29
37
  "use client";
30
38
 
31
- import { useMemo } from "react";
32
39
  import { StreamingMarkdown } from "stream-mdx";
33
- import { createDefaultWorker, releaseDefaultWorker } from "stream-mdx/worker";
34
40
 
35
41
  export function Demo({ text }: { text: string }) {
36
- const worker = useMemo(() => createDefaultWorker(), []);
37
-
38
42
  return (
39
43
  <StreamingMarkdown
40
- worker={worker}
41
- value={text}
42
- onFinalize={() => releaseDefaultWorker(worker)}
44
+ text={text}
45
+ worker="/workers/markdown-worker.js"
46
+ features={{ html: true, tables: true, math: true, mdx: true }}
47
+ mdxCompileMode="worker"
43
48
  />
44
49
  );
45
50
  }
46
51
  ```
47
52
 
48
- If you’re in Next.js App Router and you accidentally import `StreamingMarkdown` from a **server component**, you’ll typically see `useRef is not a function` (React Server condition). Fix by moving the import into a `"use client"` boundary.
49
-
50
- ## What you can customize (high level)
51
-
52
- `stream-mdx` is designed to be modular:
53
-
54
- - Disable features: math, raw HTML, MDX compilation/hydration, etc (exact flags depend on your chosen plugin set + worker config).
55
- - Swap rendering for tags: override `a`, `code`, `pre`, `table`, `thead`, `tr`, `td`, etc (e.g. Shadcn wrappers).
56
- - Wrap expensive blocks (code blocks, math blocks) in your own containers (e.g. horizontal scroll) without touching the internal incremental rendering/backpressure logic.
57
- - Change math delimiters: provide a different math tokenizer/config via plugins if you prefer `\\(...\\)` and `\\[...\\]` instead of `$...$` / `$$...$$`.
58
-
59
- ## Plugins
60
-
61
- Plugins live in `stream-mdx/plugins` (or `@stream-mdx/plugins`). Common entrypoints:
53
+ If you import `StreamingMarkdown` from a server component, you’ll typically see `useRef is not a function`. Fix by moving the import behind a `"use client"` boundary.
62
54
 
63
- - `@stream-mdx/plugins/document` – recommended default “doc plugins” bundle
64
- - `@stream-mdx/plugins/tables` – table handling
65
- - `@stream-mdx/plugins/html` – inline/raw HTML handling + sanitization hooks
66
- - `@stream-mdx/plugins/math` – math tokenization + rendering
67
- - `@stream-mdx/plugins/mdx` – MDX compilation/hydration helpers
55
+ ### Vite React
68
56
 
69
- For an end-to-end walkthrough (worker + renderer registration, CSP notes, math/MDX examples), see the repo docs:
70
- - https://github.com/kmccleary3301/stream-mdx/tree/main/docs
71
-
72
- ## MDX compilation parity (server vs worker)
57
+ ```tsx
58
+ import { StreamingMarkdown } from "stream-mdx";
73
59
 
74
- The project aims for **identical MDX compilation results** whether MDX is compiled:
60
+ export default function App() {
61
+ return (
62
+ <StreamingMarkdown
63
+ text="## Hello\n\nStreaming **markdown**"
64
+ worker="/workers/markdown-worker.js"
65
+ features={{ html: true, tables: true, math: true }}
66
+ />
67
+ );
68
+ }
69
+ ```
75
70
 
76
- - in the worker, or
77
- - on the server (API endpoint) and hydrated on the client.
71
+ ## Configuration at a glance
78
72
 
79
- This avoids “it looks different depending on where it compiled” drift. Start from:
80
- - `docs/REACT_INTEGRATION_GUIDE.md` (repo)
81
- - `docs/PUBLIC_API.md` (repo)
73
+ - `text` / `stream`: provide a full string or an append-only `AsyncIterable<string>`.
74
+ - `worker`: a `Worker`, `URL`, URL string, or factory; defaults to the built-in worker strategy and falls back to `/workers/markdown-worker.js`.
75
+ - `features`: `{ html?, tables?, mdx?, math?, footnotes?, callouts? }`.
76
+ - `mdxCompileMode`: `"worker"` (no server) or `"server"` (requires an endpoint; see docs).
77
+ - `components` / `inlineComponents`: override block + inline renders (wrap code/math without losing incremental rendering).
78
+ - `tableElements`: override table tags (e.g. Shadcn table wrappers).
79
+ - `htmlElements`: override HTML tag renders (when HTML is enabled).
80
+ - `mdxComponents`: MDX component registry (when MDX compilation is enabled).
81
+ - `scheduling`: patch scheduler/backpressure knobs.
82
82
 
83
- ## Security / HTML
83
+ ## Plugins
84
84
 
85
- If you enable raw HTML, treat it as an XSS surface:
85
+ Common entrypoints (convenience package):
86
86
 
87
- - Use the worker to isolate parsing.
88
- - Keep sanitization enabled (or provide your own schema).
89
- - Set a CSP appropriate for your deployment (especially if you allow embeds).
87
+ - `stream-mdx/plugins/document`
88
+ - `stream-mdx/plugins/tables`
89
+ - `stream-mdx/plugins/html`
90
+ - `stream-mdx/plugins/math`
91
+ - `stream-mdx/plugins/mdx`
90
92
 
91
- Start from:
92
- - `docs/STREAMING_MARKDOWN_V2_STATUS.md`
93
- - `docs/STREAMING_MARKDOWN_RELEASE_CHECKLIST.md`
93
+ Scoped equivalents:
94
94
 
95
- ## Performance notes
95
+ - `@stream-mdx/plugins/document` (etc)
96
96
 
97
- The renderer is optimized for incremental updates (streaming text), coalesced patch application, and backpressure to prevent UI lockups on large documents.
97
+ ## Docs
98
98
 
99
- If you’re benchmarking, start from:
100
- - `docs/STREAMING_V2_BENCHMARKS.md`
101
- - `docs/SNIPPET_ANALYSIS.md`
99
+ - Docs site: https://kmccleary3301.github.io/stream-mdx/
100
+ - Manual: `docs/COMPREHENSIVE_PROJECT_DOCUMENTATION.md`
101
+ - API: `docs/PUBLIC_API.md`
102
+ - React integration: `docs/REACT_INTEGRATION_GUIDE.md`
103
+ - Plugins cookbook: `docs/STREAMING_MARKDOWN_PLUGINS_COOKBOOK.md`
104
+ - Status/architecture notes: `docs/STREAMING_MARKDOWN_V2_STATUS.md`
105
+ - Release checklist: `docs/STREAMING_MARKDOWN_RELEASE_CHECKLIST.md`
102
106
 
103
107
  ## Package map
104
108
 
105
- If you need lower-level entrypoints, use:
106
-
107
- - `stream-mdx/react` – React renderer + scheduler + types
109
+ - `stream-mdx` React surface (`@stream-mdx/react`)
110
+ - `stream-mdx/react` – React renderer + types
108
111
  - `stream-mdx/worker` – worker client + default worker helpers
109
- - `stream-mdx/plugins` – plugin modules (math/MDX/tables/etc)
112
+ - `stream-mdx/plugins` – plugin registry + helpers
113
+ - `stream-mdx/plugins/*` – common plugin entrypoints
110
114
  - `stream-mdx/core` – structured-clone-safe types + perf utilities
package/dist/core.cjs CHANGED
@@ -22,4 +22,3 @@ __reExport(core_exports, require("@stream-mdx/core"), module.exports);
22
22
  0 && (module.exports = {
23
23
  ...require("@stream-mdx/core")
24
24
  });
25
- //# sourceMappingURL=core.cjs.map
package/dist/core.d.cts CHANGED
@@ -2,3 +2,15 @@ export * from '@stream-mdx/core';
2
2
  import '@stream-mdx/react';
3
3
  import '@stream-mdx/plugins';
4
4
  import '@stream-mdx/worker';
5
+ import '@stream-mdx/plugins/base';
6
+ import '@stream-mdx/plugins/callouts';
7
+ import '@stream-mdx/plugins/document';
8
+ import '@stream-mdx/plugins/footnotes';
9
+ import '@stream-mdx/plugins/html';
10
+ import '@stream-mdx/plugins/math';
11
+ import '@stream-mdx/plugins/mdx';
12
+ import '@stream-mdx/plugins/registry';
13
+ import '@stream-mdx/plugins/tables';
14
+ import '@stream-mdx/worker/mdx-compile';
15
+ import '@stream-mdx/worker/node';
16
+ import '@stream-mdx/plugins/math/renderer';
package/dist/core.d.ts CHANGED
@@ -2,3 +2,15 @@ export * from '@stream-mdx/core';
2
2
  import '@stream-mdx/react';
3
3
  import '@stream-mdx/plugins';
4
4
  import '@stream-mdx/worker';
5
+ import '@stream-mdx/plugins/base';
6
+ import '@stream-mdx/plugins/callouts';
7
+ import '@stream-mdx/plugins/document';
8
+ import '@stream-mdx/plugins/footnotes';
9
+ import '@stream-mdx/plugins/html';
10
+ import '@stream-mdx/plugins/math';
11
+ import '@stream-mdx/plugins/mdx';
12
+ import '@stream-mdx/plugins/registry';
13
+ import '@stream-mdx/plugins/tables';
14
+ import '@stream-mdx/worker/mdx-compile';
15
+ import '@stream-mdx/worker/node';
16
+ import '@stream-mdx/plugins/math/renderer';
package/dist/core.mjs CHANGED
@@ -1,3 +1,2 @@
1
1
  // src/core.ts
2
2
  export * from "@stream-mdx/core";
3
- //# sourceMappingURL=core.mjs.map
package/dist/index.cjs CHANGED
@@ -22,4 +22,3 @@ __reExport(index_exports, require("@stream-mdx/react"), module.exports);
22
22
  0 && (module.exports = {
23
23
  ...require("@stream-mdx/react")
24
24
  });
25
- //# sourceMappingURL=index.cjs.map
package/dist/index.mjs CHANGED
@@ -1,3 +1,2 @@
1
1
  // src/index.ts
2
2
  export * from "@stream-mdx/react";
3
- //# sourceMappingURL=index.mjs.map
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/base.ts
18
+ var base_exports = {};
19
+ module.exports = __toCommonJS(base_exports);
20
+ __reExport(base_exports, require("@stream-mdx/plugins/base"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/base")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/base';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/base';
@@ -0,0 +1,2 @@
1
+ // src/plugins/base.ts
2
+ export * from "@stream-mdx/plugins/base";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/callouts.ts
18
+ var callouts_exports = {};
19
+ module.exports = __toCommonJS(callouts_exports);
20
+ __reExport(callouts_exports, require("@stream-mdx/plugins/callouts"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/callouts")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/callouts';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/callouts';
@@ -0,0 +1,2 @@
1
+ // src/plugins/callouts.ts
2
+ export * from "@stream-mdx/plugins/callouts";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/document.ts
18
+ var document_exports = {};
19
+ module.exports = __toCommonJS(document_exports);
20
+ __reExport(document_exports, require("@stream-mdx/plugins/document"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/document")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/document';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/document';
@@ -0,0 +1,2 @@
1
+ // src/plugins/document.ts
2
+ export * from "@stream-mdx/plugins/document";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/footnotes.ts
18
+ var footnotes_exports = {};
19
+ module.exports = __toCommonJS(footnotes_exports);
20
+ __reExport(footnotes_exports, require("@stream-mdx/plugins/footnotes"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/footnotes")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/footnotes';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/footnotes';
@@ -0,0 +1,2 @@
1
+ // src/plugins/footnotes.ts
2
+ export * from "@stream-mdx/plugins/footnotes";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/html.ts
18
+ var html_exports = {};
19
+ module.exports = __toCommonJS(html_exports);
20
+ __reExport(html_exports, require("@stream-mdx/plugins/html"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/html")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/html';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/html';
@@ -0,0 +1,2 @@
1
+ // src/plugins/html.ts
2
+ export * from "@stream-mdx/plugins/html";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/math/renderer.ts
18
+ var renderer_exports = {};
19
+ module.exports = __toCommonJS(renderer_exports);
20
+ __reExport(renderer_exports, require("@stream-mdx/plugins/math/renderer"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/math/renderer")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/math/renderer';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/math/renderer';
@@ -0,0 +1,2 @@
1
+ // src/plugins/math/renderer.ts
2
+ export * from "@stream-mdx/plugins/math/renderer";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/math.ts
18
+ var math_exports = {};
19
+ module.exports = __toCommonJS(math_exports);
20
+ __reExport(math_exports, require("@stream-mdx/plugins/math"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/math")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/math';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/math';
@@ -0,0 +1,2 @@
1
+ // src/plugins/math.ts
2
+ export * from "@stream-mdx/plugins/math";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/mdx.ts
18
+ var mdx_exports = {};
19
+ module.exports = __toCommonJS(mdx_exports);
20
+ __reExport(mdx_exports, require("@stream-mdx/plugins/mdx"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/mdx")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/mdx';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/mdx';
@@ -0,0 +1,2 @@
1
+ // src/plugins/mdx.ts
2
+ export * from "@stream-mdx/plugins/mdx";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/registry.ts
18
+ var registry_exports = {};
19
+ module.exports = __toCommonJS(registry_exports);
20
+ __reExport(registry_exports, require("@stream-mdx/plugins/registry"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/registry")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/registry';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/registry';
@@ -0,0 +1,2 @@
1
+ // src/plugins/registry.ts
2
+ export * from "@stream-mdx/plugins/registry";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/plugins/tables.ts
18
+ var tables_exports = {};
19
+ module.exports = __toCommonJS(tables_exports);
20
+ __reExport(tables_exports, require("@stream-mdx/plugins/tables"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/plugins/tables")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/tables';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/plugins/tables';
@@ -0,0 +1,2 @@
1
+ // src/plugins/tables.ts
2
+ export * from "@stream-mdx/plugins/tables";
package/dist/plugins.cjs CHANGED
@@ -22,4 +22,3 @@ __reExport(plugins_exports, require("@stream-mdx/plugins"), module.exports);
22
22
  0 && (module.exports = {
23
23
  ...require("@stream-mdx/plugins")
24
24
  });
25
- //# sourceMappingURL=plugins.cjs.map
package/dist/plugins.mjs CHANGED
@@ -1,3 +1,2 @@
1
1
  // src/plugins.ts
2
2
  export * from "@stream-mdx/plugins";
3
- //# sourceMappingURL=plugins.mjs.map
package/dist/react.cjs CHANGED
@@ -22,4 +22,3 @@ __reExport(react_exports, require("@stream-mdx/react"), module.exports);
22
22
  0 && (module.exports = {
23
23
  ...require("@stream-mdx/react")
24
24
  });
25
- //# sourceMappingURL=react.cjs.map
package/dist/react.mjs CHANGED
@@ -1,3 +1,2 @@
1
1
  // src/react.ts
2
2
  export * from "@stream-mdx/react";
3
- //# sourceMappingURL=react.mjs.map
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/worker/mdx-compile.ts
18
+ var mdx_compile_exports = {};
19
+ module.exports = __toCommonJS(mdx_compile_exports);
20
+ __reExport(mdx_compile_exports, require("@stream-mdx/worker/mdx-compile"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/worker/mdx-compile")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/worker/mdx-compile';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/worker/mdx-compile';
@@ -0,0 +1,2 @@
1
+ // src/worker/mdx-compile.ts
2
+ export * from "@stream-mdx/worker/mdx-compile";
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/worker/node.ts
18
+ var node_exports = {};
19
+ module.exports = __toCommonJS(node_exports);
20
+ __reExport(node_exports, require("@stream-mdx/worker/node"), module.exports);
21
+ // Annotate the CommonJS export names for ESM import in node:
22
+ 0 && (module.exports = {
23
+ ...require("@stream-mdx/worker/node")
24
+ });
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/worker/node';
@@ -0,0 +1 @@
1
+ export * from '@stream-mdx/worker/node';
@@ -0,0 +1,2 @@
1
+ // src/worker/node.ts
2
+ export * from "@stream-mdx/worker/node";
package/dist/worker.cjs CHANGED
@@ -22,4 +22,3 @@ __reExport(worker_exports, require("@stream-mdx/worker"), module.exports);
22
22
  0 && (module.exports = {
23
23
  ...require("@stream-mdx/worker")
24
24
  });
25
- //# sourceMappingURL=worker.cjs.map
package/dist/worker.mjs CHANGED
@@ -1,3 +1,2 @@
1
1
  // src/worker.ts
2
2
  export * from "@stream-mdx/worker";
3
- //# sourceMappingURL=worker.mjs.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "stream-mdx",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "description": "StreamMDX convenience package (re-exports @stream-mdx/*).",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -36,15 +36,76 @@
36
36
  "import": "./dist/worker.mjs",
37
37
  "require": "./dist/worker.cjs"
38
38
  },
39
+ "./worker/mdx-compile": {
40
+ "types": "./dist/worker/mdx-compile.d.ts",
41
+ "import": "./dist/worker/mdx-compile.mjs",
42
+ "require": "./dist/worker/mdx-compile.cjs"
43
+ },
44
+ "./worker/node": {
45
+ "types": "./dist/worker/node.d.ts",
46
+ "import": "./dist/worker/node.mjs",
47
+ "require": "./dist/worker/node.cjs"
48
+ },
39
49
  "./plugins": {
40
50
  "types": "./dist/plugins.d.ts",
41
51
  "import": "./dist/plugins.mjs",
42
52
  "require": "./dist/plugins.cjs"
53
+ },
54
+ "./plugins/base": {
55
+ "types": "./dist/plugins/base.d.ts",
56
+ "import": "./dist/plugins/base.mjs",
57
+ "require": "./dist/plugins/base.cjs"
58
+ },
59
+ "./plugins/registry": {
60
+ "types": "./dist/plugins/registry.d.ts",
61
+ "import": "./dist/plugins/registry.mjs",
62
+ "require": "./dist/plugins/registry.cjs"
63
+ },
64
+ "./plugins/callouts": {
65
+ "types": "./dist/plugins/callouts.d.ts",
66
+ "import": "./dist/plugins/callouts.mjs",
67
+ "require": "./dist/plugins/callouts.cjs"
68
+ },
69
+ "./plugins/document": {
70
+ "types": "./dist/plugins/document.d.ts",
71
+ "import": "./dist/plugins/document.mjs",
72
+ "require": "./dist/plugins/document.cjs"
73
+ },
74
+ "./plugins/footnotes": {
75
+ "types": "./dist/plugins/footnotes.d.ts",
76
+ "import": "./dist/plugins/footnotes.mjs",
77
+ "require": "./dist/plugins/footnotes.cjs"
78
+ },
79
+ "./plugins/html": {
80
+ "types": "./dist/plugins/html.d.ts",
81
+ "import": "./dist/plugins/html.mjs",
82
+ "require": "./dist/plugins/html.cjs"
83
+ },
84
+ "./plugins/math": {
85
+ "types": "./dist/plugins/math.d.ts",
86
+ "import": "./dist/plugins/math.mjs",
87
+ "require": "./dist/plugins/math.cjs"
88
+ },
89
+ "./plugins/math/renderer": {
90
+ "types": "./dist/plugins/math/renderer.d.ts",
91
+ "import": "./dist/plugins/math/renderer.mjs",
92
+ "require": "./dist/plugins/math/renderer.cjs"
93
+ },
94
+ "./plugins/mdx": {
95
+ "types": "./dist/plugins/mdx.d.ts",
96
+ "import": "./dist/plugins/mdx.mjs",
97
+ "require": "./dist/plugins/mdx.cjs"
98
+ },
99
+ "./plugins/tables": {
100
+ "types": "./dist/plugins/tables.d.ts",
101
+ "import": "./dist/plugins/tables.mjs",
102
+ "require": "./dist/plugins/tables.cjs"
43
103
  }
44
104
  },
45
105
  "files": [
46
106
  "dist",
47
- "README.md"
107
+ "README.md",
108
+ "CHANGELOG.md"
48
109
  ],
49
110
  "sideEffects": false,
50
111
  "scripts": {
@@ -53,10 +114,10 @@
53
114
  "prepack": "npm run build"
54
115
  },
55
116
  "dependencies": {
56
- "@stream-mdx/core": "0.0.1",
57
- "@stream-mdx/plugins": "0.0.1",
58
- "@stream-mdx/react": "0.0.1",
59
- "@stream-mdx/worker": "0.0.1"
117
+ "@stream-mdx/core": "0.0.3",
118
+ "@stream-mdx/plugins": "0.0.3",
119
+ "@stream-mdx/react": "0.0.3",
120
+ "@stream-mdx/worker": "0.0.3"
60
121
  },
61
122
  "peerDependencies": {
62
123
  "react": ">=18.2.0",
package/dist/core.cjs.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/core.ts"],"sourcesContent":["export * from \"@stream-mdx/core\";\n\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,yBAAc,6BAAd;","names":[]}
package/dist/core.mjs.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/core.ts"],"sourcesContent":["export * from \"@stream-mdx/core\";\n\n"],"mappings":";AAAA,cAAc;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export * from \"@stream-mdx/react\";\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,0BAAc,8BAAd;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["export * from \"@stream-mdx/react\";\n"],"mappings":";AAAA,cAAc;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/plugins.ts"],"sourcesContent":["export * from \"@stream-mdx/plugins\";\n\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,4BAAc,gCAAd;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/plugins.ts"],"sourcesContent":["export * from \"@stream-mdx/plugins\";\n\n"],"mappings":";AAAA,cAAc;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/react.ts"],"sourcesContent":["export * from \"@stream-mdx/react\";\n\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,0BAAc,8BAAd;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/react.ts"],"sourcesContent":["export * from \"@stream-mdx/react\";\n\n"],"mappings":";AAAA,cAAc;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/worker.ts"],"sourcesContent":["export * from \"@stream-mdx/worker\";\n\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,2BAAc,+BAAd;","names":[]}
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../src/worker.ts"],"sourcesContent":["export * from \"@stream-mdx/worker\";\n\n"],"mappings":";AAAA,cAAc;","names":[]}