fumadocs-mdx 14.0.4 → 14.1.0
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.
- package/dist/{build-mdx-W3233QBZ.js → build-mdx-RXJZQXGA.js} +2 -2
- package/dist/bun/index.d.ts +2 -2
- package/dist/bun/index.js +6 -6
- package/dist/{chunk-KOPLIEVQ.js → chunk-7W73RILB.js} +2 -1
- package/dist/{chunk-LPX7ZO66.js → chunk-DTFUANSF.js} +1 -1
- package/dist/{chunk-CGGDM5F3.js → chunk-K7N6GD4M.js} +1 -1
- package/dist/{chunk-6RPNS75C.js → chunk-OLD35ARB.js} +43 -31
- package/dist/{chunk-WBIHDYMN.js → chunk-PW2AZGGD.js} +3 -4
- package/dist/{chunk-USWQVJWR.js → chunk-T6G5VOED.js} +21 -12
- package/dist/{chunk-ED3ON275.js → chunk-VITVHHR6.js} +85 -81
- package/dist/{chunk-K4KWUM3J.js → chunk-VKSHE52K.js} +83 -34
- package/dist/{chunk-NKIL543T.js → chunk-WAAWFNDX.js} +18 -20
- package/dist/{chunk-FBLMK4RS.js → chunk-Y7ISNZ7X.js} +22 -16
- package/dist/{chunk-TYJDYTKH.js → chunk-ZAYZWFWP.js} +10 -6
- package/dist/config/index.d.ts +2 -2
- package/dist/config/index.js +6 -5
- package/dist/{core-C3QZSdEx.d.ts → core-X5ggQtBM.d.ts} +50 -41
- package/dist/index-BqkSNsGO.d.ts +8 -0
- package/dist/index.d.ts +2 -2
- package/dist/{load-from-file-OZ5N7DXU.js → load-from-file-FHW724YY.js} +2 -2
- package/dist/next/index.cjs +251 -201
- package/dist/next/index.d.ts +2 -2
- package/dist/next/index.js +21 -36
- package/dist/node/loader.js +5 -5
- package/dist/plugins/index-file.d.ts +2 -2
- package/dist/plugins/index-file.js +2 -2
- package/dist/plugins/json-schema.d.ts +2 -2
- package/dist/plugins/json-schema.js +4 -7
- package/dist/plugins/last-modified.d.ts +2 -2
- package/dist/plugins/last-modified.js +20 -13
- package/dist/runtime/browser.d.ts +2 -2
- package/dist/runtime/dynamic.d.ts +2 -2
- package/dist/runtime/dynamic.js +6 -6
- package/dist/runtime/server.d.ts +2 -2
- package/dist/vite/index.d.ts +2 -2
- package/dist/vite/index.js +16 -18
- package/dist/webpack/mdx.d.ts +1 -15
- package/dist/webpack/mdx.js +5 -5
- package/dist/webpack/meta.d.ts +1 -15
- package/dist/webpack/meta.js +5 -5
- package/package.json +12 -13
- package/dist/index-DG1I0CwF.d.ts +0 -8
package/dist/next/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { NextConfig } from 'next';
|
|
2
|
-
import { I as IndexFilePluginOptions } from '../core-
|
|
2
|
+
import { I as IndexFilePluginOptions } from '../core-X5ggQtBM.js';
|
|
3
3
|
import '@mdx-js/mdx';
|
|
4
4
|
import '@standard-schema/spec';
|
|
5
5
|
import 'unified';
|
|
6
6
|
import 'fumadocs-core/mdx-plugins';
|
|
7
|
-
import '
|
|
7
|
+
import 'fumadocs-core/source/schema';
|
|
8
8
|
import 'chokidar';
|
|
9
9
|
import 'vfile';
|
|
10
10
|
import 'fumadocs-core/source';
|
package/dist/next/index.js
CHANGED
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
import {
|
|
2
2
|
loadConfig
|
|
3
|
-
} from "../chunk-
|
|
4
|
-
import "../chunk-
|
|
3
|
+
} from "../chunk-DTFUANSF.js";
|
|
4
|
+
import "../chunk-OLD35ARB.js";
|
|
5
5
|
import "../chunk-S7KOJHHO.js";
|
|
6
6
|
import {
|
|
7
7
|
mdxLoaderGlob,
|
|
8
8
|
metaLoaderGlob
|
|
9
9
|
} from "../chunk-4JSFLXXT.js";
|
|
10
10
|
import {
|
|
11
|
-
ValidationError,
|
|
12
11
|
_Defaults,
|
|
13
12
|
createCore
|
|
14
|
-
} from "../chunk-
|
|
13
|
+
} from "../chunk-VKSHE52K.js";
|
|
15
14
|
import {
|
|
16
15
|
indexFile
|
|
17
|
-
} from "../chunk-
|
|
18
|
-
import "../chunk-
|
|
16
|
+
} from "../chunk-VITVHHR6.js";
|
|
17
|
+
import "../chunk-PW2AZGGD.js";
|
|
19
18
|
import "../chunk-VWJKRQZR.js";
|
|
20
19
|
|
|
21
20
|
// src/next/index.ts
|
|
@@ -29,8 +28,10 @@ function createMDX(createOptions = {}) {
|
|
|
29
28
|
void init(isDev, core);
|
|
30
29
|
}
|
|
31
30
|
return (nextConfig = {}) => {
|
|
31
|
+
const { configPath, outDir } = core.getOptions();
|
|
32
32
|
const loaderOptions = {
|
|
33
|
-
|
|
33
|
+
configPath,
|
|
34
|
+
outDir,
|
|
34
35
|
absoluteCompiledConfigPath: path.resolve(core.getCompiledConfigPath()),
|
|
35
36
|
isDev
|
|
36
37
|
};
|
|
@@ -108,7 +109,7 @@ async function init(dev, core) {
|
|
|
108
109
|
await core.init({
|
|
109
110
|
config: loadConfig(core, true)
|
|
110
111
|
});
|
|
111
|
-
await core.
|
|
112
|
+
await core.emit({ write: true });
|
|
112
113
|
}
|
|
113
114
|
async function devServer() {
|
|
114
115
|
const { FSWatcher } = await import("chokidar");
|
|
@@ -119,11 +120,11 @@ async function init(dev, core) {
|
|
|
119
120
|
ignored: [outDir]
|
|
120
121
|
});
|
|
121
122
|
watcher.add(configPath);
|
|
122
|
-
for (const collection of core.
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
123
|
+
for (const collection of core.getCollections()) {
|
|
124
|
+
watcher.add(collection.dir);
|
|
125
|
+
}
|
|
126
|
+
for (const workspace of core.getWorkspaces().values()) {
|
|
127
|
+
for (const collection of workspace.getCollections()) {
|
|
127
128
|
watcher.add(collection.dir);
|
|
128
129
|
}
|
|
129
130
|
}
|
|
@@ -157,7 +158,7 @@ async function postInstall(options) {
|
|
|
157
158
|
await core.init({
|
|
158
159
|
config: loadConfig(core, true)
|
|
159
160
|
});
|
|
160
|
-
await core.
|
|
161
|
+
await core.emit({ write: true });
|
|
161
162
|
}
|
|
162
163
|
function applyDefaults(options) {
|
|
163
164
|
return {
|
|
@@ -167,28 +168,12 @@ function applyDefaults(options) {
|
|
|
167
168
|
};
|
|
168
169
|
}
|
|
169
170
|
function createNextCore(options) {
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
[options.index && indexFile(options.index)]
|
|
177
|
-
);
|
|
178
|
-
return {
|
|
179
|
-
...core,
|
|
180
|
-
async emitAndWrite(...args) {
|
|
181
|
-
try {
|
|
182
|
-
await core.emitAndWrite(...args);
|
|
183
|
-
} catch (err) {
|
|
184
|
-
if (err instanceof ValidationError) {
|
|
185
|
-
console.error(await err.toStringFormatted());
|
|
186
|
-
} else {
|
|
187
|
-
console.error(err);
|
|
188
|
-
}
|
|
189
|
-
}
|
|
190
|
-
}
|
|
191
|
-
};
|
|
171
|
+
return createCore({
|
|
172
|
+
environment: "next",
|
|
173
|
+
outDir: options.outDir,
|
|
174
|
+
configPath: options.configPath,
|
|
175
|
+
plugins: [options.index && indexFile(options.index)]
|
|
176
|
+
});
|
|
192
177
|
}
|
|
193
178
|
export {
|
|
194
179
|
createMDX,
|
package/dist/node/loader.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createMdxLoader
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-T6G5VOED.js";
|
|
4
4
|
import {
|
|
5
5
|
createMetaLoader
|
|
6
|
-
} from "../chunk-
|
|
6
|
+
} from "../chunk-ZAYZWFWP.js";
|
|
7
7
|
import {
|
|
8
8
|
createStandaloneConfigLoader,
|
|
9
9
|
toNode
|
|
10
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-WAAWFNDX.js";
|
|
11
11
|
import "../chunk-4JSFLXXT.js";
|
|
12
12
|
import {
|
|
13
13
|
_Defaults,
|
|
14
14
|
createCore
|
|
15
|
-
} from "../chunk-
|
|
16
|
-
import "../chunk-
|
|
15
|
+
} from "../chunk-VKSHE52K.js";
|
|
16
|
+
import "../chunk-PW2AZGGD.js";
|
|
17
17
|
import "../chunk-VWJKRQZR.js";
|
|
18
18
|
|
|
19
19
|
// src/node/loader.ts
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { H as IndexFilePlugin, I as IndexFilePluginOptions, F as default } from '../core-X5ggQtBM.js';
|
|
2
2
|
import '@mdx-js/mdx';
|
|
3
3
|
import '@standard-schema/spec';
|
|
4
4
|
import 'unified';
|
|
5
5
|
import 'fumadocs-core/mdx-plugins';
|
|
6
|
-
import '
|
|
6
|
+
import 'fumadocs-core/source/schema';
|
|
7
7
|
import 'chokidar';
|
|
8
8
|
import 'vfile';
|
|
9
9
|
import 'fumadocs-core/source';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { i as Plugin } from '../core-X5ggQtBM.js';
|
|
2
2
|
import '@mdx-js/mdx';
|
|
3
3
|
import '@standard-schema/spec';
|
|
4
4
|
import 'unified';
|
|
5
5
|
import 'fumadocs-core/mdx-plugins';
|
|
6
|
-
import '
|
|
6
|
+
import 'fumadocs-core/source/schema';
|
|
7
7
|
import 'chokidar';
|
|
8
8
|
import 'vfile';
|
|
9
9
|
import 'fumadocs-core/source';
|
|
@@ -5,20 +5,17 @@ import path from "path";
|
|
|
5
5
|
function jsonSchema({
|
|
6
6
|
insert = false
|
|
7
7
|
} = {}) {
|
|
8
|
-
let config;
|
|
9
8
|
function getSchemaPath(name) {
|
|
10
9
|
return `json-schema/${name}.json`;
|
|
11
10
|
}
|
|
12
11
|
return {
|
|
13
|
-
config(v) {
|
|
14
|
-
config = v;
|
|
15
|
-
},
|
|
16
12
|
configureServer(server) {
|
|
13
|
+
const { outDir } = this.core.getOptions();
|
|
17
14
|
if (!server.watcher || !insert) return;
|
|
18
15
|
server.watcher.on("add", async (file) => {
|
|
19
16
|
let parent;
|
|
20
17
|
let match;
|
|
21
|
-
for (const collection of
|
|
18
|
+
for (const collection of this.core.getCollections()) {
|
|
22
19
|
if (collection.type === "meta" && collection.hasFile(file)) {
|
|
23
20
|
match = collection;
|
|
24
21
|
break;
|
|
@@ -39,7 +36,7 @@ function jsonSchema({
|
|
|
39
36
|
}
|
|
40
37
|
if ("$schema" in obj) return;
|
|
41
38
|
const schemaPath = path.join(
|
|
42
|
-
|
|
39
|
+
outDir,
|
|
43
40
|
getSchemaPath(parent ? `${parent.name}.meta` : match.name)
|
|
44
41
|
);
|
|
45
42
|
const updated = {
|
|
@@ -62,7 +59,7 @@ function jsonSchema({
|
|
|
62
59
|
)
|
|
63
60
|
});
|
|
64
61
|
}
|
|
65
|
-
for (const collection of
|
|
62
|
+
for (const collection of this.core.getCollections()) {
|
|
66
63
|
if (collection.type === "docs") {
|
|
67
64
|
if (collection.meta.schema instanceof z.ZodType) {
|
|
68
65
|
onSchema(`${collection.name}.meta`, collection.meta.schema);
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { i as Plugin } from '../core-X5ggQtBM.js';
|
|
2
2
|
import '@mdx-js/mdx';
|
|
3
3
|
import '@standard-schema/spec';
|
|
4
4
|
import 'unified';
|
|
5
5
|
import 'fumadocs-core/mdx-plugins';
|
|
6
|
-
import '
|
|
6
|
+
import 'fumadocs-core/source/schema';
|
|
7
7
|
import 'chokidar';
|
|
8
8
|
import 'vfile';
|
|
9
9
|
import 'fumadocs-core/source';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ident
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-PW2AZGGD.js";
|
|
4
4
|
|
|
5
5
|
// src/plugins/last-modified.ts
|
|
6
6
|
import path from "path";
|
|
@@ -16,13 +16,6 @@ var ExtendTypes = `{
|
|
|
16
16
|
function lastModified(options = {}) {
|
|
17
17
|
const { versionControl = "git", filter = () => true } = options;
|
|
18
18
|
let fn;
|
|
19
|
-
switch (versionControl) {
|
|
20
|
-
case "git":
|
|
21
|
-
fn = getGitTimestamp;
|
|
22
|
-
break;
|
|
23
|
-
default:
|
|
24
|
-
fn = versionControl;
|
|
25
|
-
}
|
|
26
19
|
return {
|
|
27
20
|
name: "last-modified",
|
|
28
21
|
"index-file": {
|
|
@@ -30,7 +23,7 @@ function lastModified(options = {}) {
|
|
|
30
23
|
const lines = [];
|
|
31
24
|
lines.push("{");
|
|
32
25
|
lines.push(" DocData: {");
|
|
33
|
-
for (const collection of this.core.
|
|
26
|
+
for (const collection of this.core.getCollections()) {
|
|
34
27
|
if (filter(collection.name)) {
|
|
35
28
|
lines.push(ident(`${collection.name}: ${ExtendTypes},`, 2));
|
|
36
29
|
}
|
|
@@ -45,6 +38,17 @@ function lastModified(options = {}) {
|
|
|
45
38
|
options2.doc.passthroughs.push("lastModified");
|
|
46
39
|
}
|
|
47
40
|
},
|
|
41
|
+
config() {
|
|
42
|
+
const { workspace } = this.core.getOptions();
|
|
43
|
+
const cwd = workspace ? path.resolve(workspace.dir) : process.cwd();
|
|
44
|
+
switch (versionControl) {
|
|
45
|
+
case "git":
|
|
46
|
+
fn = (v) => getGitTimestamp(v, cwd);
|
|
47
|
+
break;
|
|
48
|
+
default:
|
|
49
|
+
fn = versionControl;
|
|
50
|
+
}
|
|
51
|
+
},
|
|
48
52
|
doc: {
|
|
49
53
|
async vfile(file) {
|
|
50
54
|
if (!filter(this.collection.name)) return;
|
|
@@ -60,22 +64,25 @@ function lastModified(options = {}) {
|
|
|
60
64
|
}
|
|
61
65
|
};
|
|
62
66
|
}
|
|
63
|
-
async function getGitTimestamp(file) {
|
|
67
|
+
async function getGitTimestamp(file, cwd) {
|
|
64
68
|
const cached = cache.get(file);
|
|
65
69
|
if (cached) return cached;
|
|
66
70
|
const timePromise = (async () => {
|
|
67
71
|
const out = await x(
|
|
68
72
|
"git",
|
|
69
|
-
["log", "-1", '--pretty="%ai"', path.relative(
|
|
73
|
+
["log", "-1", '--pretty="%ai"', path.relative(cwd, file)],
|
|
70
74
|
{
|
|
71
|
-
|
|
75
|
+
nodeOptions: {
|
|
76
|
+
cwd
|
|
77
|
+
}
|
|
72
78
|
}
|
|
73
79
|
);
|
|
80
|
+
if (out.exitCode !== 0) return null;
|
|
74
81
|
const date = new Date(out.stdout);
|
|
75
82
|
return isNaN(date.getTime()) ? null : date;
|
|
76
83
|
})();
|
|
77
84
|
cache.set(file, timePromise);
|
|
78
|
-
return timePromise
|
|
85
|
+
return timePromise;
|
|
79
86
|
}
|
|
80
87
|
export {
|
|
81
88
|
lastModified as default
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { ReactNode, FC } from 'react';
|
|
2
2
|
import { StandardSchemaV1 } from '@standard-schema/spec';
|
|
3
|
-
import { D as DocCollection, b as DocsCollection } from '../core-
|
|
3
|
+
import { D as DocCollection, b as DocsCollection } from '../core-X5ggQtBM.js';
|
|
4
4
|
import { CompiledMDXProperties } from '../index.js';
|
|
5
5
|
import { InternalTypeConfig } from './types.js';
|
|
6
6
|
import '@mdx-js/mdx';
|
|
7
7
|
import 'unified';
|
|
8
8
|
import 'fumadocs-core/mdx-plugins';
|
|
9
|
-
import '
|
|
9
|
+
import 'fumadocs-core/source/schema';
|
|
10
10
|
import 'chokidar';
|
|
11
11
|
import 'vfile';
|
|
12
12
|
import 'fumadocs-core/source';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import * as fumadocs_core_source from 'fumadocs-core/source';
|
|
2
|
-
import { C as CoreOptions, S as ServerOptions, D as DocCollection, b as DocsCollection,
|
|
2
|
+
import { C as CoreOptions, S as ServerOptions, D as DocCollection, b as DocsCollection, j as AsyncDocCollectionEntry, k as AsyncDocsCollectionEntry } from '../core-X5ggQtBM.js';
|
|
3
3
|
import * as _standard_schema_spec from '@standard-schema/spec';
|
|
4
4
|
import { FileInfo, InternalTypeConfig } from './types.js';
|
|
5
5
|
import '@mdx-js/mdx';
|
|
6
6
|
import 'unified';
|
|
7
7
|
import 'fumadocs-core/mdx-plugins';
|
|
8
|
-
import '
|
|
8
|
+
import 'fumadocs-core/source/schema';
|
|
9
9
|
import 'chokidar';
|
|
10
10
|
import 'vfile';
|
|
11
11
|
import 'fumadocs-core/mdx-plugins/remark-structure';
|
package/dist/runtime/dynamic.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
buildMDX
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-7W73RILB.js";
|
|
4
4
|
import {
|
|
5
5
|
server
|
|
6
6
|
} from "../chunk-5OBUOALK.js";
|
|
7
|
-
import "../chunk-
|
|
7
|
+
import "../chunk-Y7ISNZ7X.js";
|
|
8
8
|
import {
|
|
9
9
|
buildConfig
|
|
10
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-OLD35ARB.js";
|
|
11
11
|
import "../chunk-S7KOJHHO.js";
|
|
12
12
|
import {
|
|
13
13
|
createCore
|
|
14
|
-
} from "../chunk-
|
|
15
|
-
import "../chunk-
|
|
14
|
+
} from "../chunk-VKSHE52K.js";
|
|
15
|
+
import "../chunk-PW2AZGGD.js";
|
|
16
16
|
import {
|
|
17
17
|
fumaMatter
|
|
18
18
|
} from "../chunk-VWJKRQZR.js";
|
|
@@ -28,7 +28,7 @@ async function dynamic(configExports, coreOptions, serverOptions) {
|
|
|
28
28
|
});
|
|
29
29
|
const create = server(serverOptions);
|
|
30
30
|
function getDocCollection(name) {
|
|
31
|
-
const collection = core.
|
|
31
|
+
const collection = core.getCollection(name);
|
|
32
32
|
if (!collection) return;
|
|
33
33
|
if (collection.type === "docs") return collection.docs;
|
|
34
34
|
else if (collection.type === "doc") return collection;
|
package/dist/runtime/server.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import 'fumadocs-core/source';
|
|
2
|
-
export {
|
|
2
|
+
export { j as AsyncDocCollectionEntry, k as AsyncDocsCollectionEntry, v as DocCollectionEntry, w as DocsCollectionEntry, u as MetaCollectionEntry, x as ServerCreate, S as ServerOptions, y as server, z as toFumadocsSource } from '../core-X5ggQtBM.js';
|
|
3
3
|
import '@standard-schema/spec';
|
|
4
4
|
import './types.js';
|
|
5
5
|
import '@mdx-js/mdx';
|
|
6
6
|
import 'unified';
|
|
7
7
|
import 'fumadocs-core/mdx-plugins';
|
|
8
|
-
import '
|
|
8
|
+
import 'fumadocs-core/source/schema';
|
|
9
9
|
import 'chokidar';
|
|
10
10
|
import 'vfile';
|
|
11
11
|
import 'fumadocs-core/mdx-plugins/remark-structure';
|
package/dist/vite/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { Plugin } from 'vite';
|
|
2
|
-
import { I as IndexFilePluginOptions } from '../core-
|
|
2
|
+
import { I as IndexFilePluginOptions } from '../core-X5ggQtBM.js';
|
|
3
3
|
import '@mdx-js/mdx';
|
|
4
4
|
import '@standard-schema/spec';
|
|
5
5
|
import 'unified';
|
|
6
6
|
import 'fumadocs-core/mdx-plugins';
|
|
7
|
-
import '
|
|
7
|
+
import 'fumadocs-core/source/schema';
|
|
8
8
|
import 'chokidar';
|
|
9
9
|
import 'vfile';
|
|
10
10
|
import 'fumadocs-core/source';
|
package/dist/vite/index.js
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
1
|
import {
|
|
2
2
|
buildConfig
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-OLD35ARB.js";
|
|
4
4
|
import "../chunk-S7KOJHHO.js";
|
|
5
5
|
import {
|
|
6
6
|
createMdxLoader
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-T6G5VOED.js";
|
|
8
8
|
import {
|
|
9
9
|
createMetaLoader
|
|
10
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-ZAYZWFWP.js";
|
|
11
11
|
import {
|
|
12
12
|
createIntegratedConfigLoader,
|
|
13
13
|
toVite
|
|
14
|
-
} from "../chunk-
|
|
14
|
+
} from "../chunk-WAAWFNDX.js";
|
|
15
15
|
import "../chunk-4JSFLXXT.js";
|
|
16
16
|
import {
|
|
17
17
|
ValidationError,
|
|
18
18
|
_Defaults,
|
|
19
19
|
createCore
|
|
20
|
-
} from "../chunk-
|
|
20
|
+
} from "../chunk-VKSHE52K.js";
|
|
21
21
|
import {
|
|
22
22
|
indexFile
|
|
23
|
-
} from "../chunk-
|
|
24
|
-
import "../chunk-
|
|
23
|
+
} from "../chunk-VITVHHR6.js";
|
|
24
|
+
import "../chunk-PW2AZGGD.js";
|
|
25
25
|
import "../chunk-VWJKRQZR.js";
|
|
26
26
|
|
|
27
27
|
// src/vite/index.ts
|
|
@@ -58,7 +58,7 @@ async function mdx(config, pluginOptions = {}) {
|
|
|
58
58
|
});
|
|
59
59
|
},
|
|
60
60
|
async buildStart() {
|
|
61
|
-
await core.
|
|
61
|
+
await core.emit({ write: true });
|
|
62
62
|
},
|
|
63
63
|
async configureServer(server) {
|
|
64
64
|
await core.initServer({
|
|
@@ -83,12 +83,12 @@ async function mdx(config, pluginOptions = {}) {
|
|
|
83
83
|
};
|
|
84
84
|
}
|
|
85
85
|
async function postInstall(pluginOptions = {}) {
|
|
86
|
-
const { loadConfig } = await import("../load-from-file-
|
|
86
|
+
const { loadConfig } = await import("../load-from-file-FHW724YY.js");
|
|
87
87
|
const core = createViteCore(applyDefaults(pluginOptions));
|
|
88
88
|
await core.init({
|
|
89
89
|
config: loadConfig(core, true)
|
|
90
90
|
});
|
|
91
|
-
await core.
|
|
91
|
+
await core.emit({ write: true });
|
|
92
92
|
}
|
|
93
93
|
function createViteCore({
|
|
94
94
|
index,
|
|
@@ -96,19 +96,17 @@ function createViteCore({
|
|
|
96
96
|
outDir
|
|
97
97
|
}) {
|
|
98
98
|
if (index === true) index = {};
|
|
99
|
-
return createCore(
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
},
|
|
105
|
-
[
|
|
99
|
+
return createCore({
|
|
100
|
+
environment: "vite",
|
|
101
|
+
configPath,
|
|
102
|
+
outDir,
|
|
103
|
+
plugins: [
|
|
106
104
|
index && indexFile({
|
|
107
105
|
...index,
|
|
108
106
|
target: index.target ?? "vite"
|
|
109
107
|
})
|
|
110
108
|
]
|
|
111
|
-
);
|
|
109
|
+
});
|
|
112
110
|
}
|
|
113
111
|
function applyDefaults(options) {
|
|
114
112
|
return {
|
package/dist/webpack/mdx.d.ts
CHANGED
|
@@ -1,19 +1,5 @@
|
|
|
1
1
|
import { LoaderContext } from 'webpack';
|
|
2
|
-
import { W as WebpackLoaderOptions } from '../index-
|
|
3
|
-
import '../core-C3QZSdEx.js';
|
|
4
|
-
import '@mdx-js/mdx';
|
|
5
|
-
import '@standard-schema/spec';
|
|
6
|
-
import 'unified';
|
|
7
|
-
import 'fumadocs-core/mdx-plugins';
|
|
8
|
-
import 'zod';
|
|
9
|
-
import 'chokidar';
|
|
10
|
-
import 'vfile';
|
|
11
|
-
import 'fumadocs-core/source';
|
|
12
|
-
import '../runtime/types.js';
|
|
13
|
-
import 'fumadocs-core/mdx-plugins/remark-structure';
|
|
14
|
-
import 'fumadocs-core/toc';
|
|
15
|
-
import 'mdast';
|
|
16
|
-
import 'mdx/types';
|
|
2
|
+
import { W as WebpackLoaderOptions } from '../index-BqkSNsGO.js';
|
|
17
3
|
|
|
18
4
|
declare function loader(this: LoaderContext<WebpackLoaderOptions>, source: string, callback: LoaderContext<WebpackLoaderOptions>['callback']): Promise<void>;
|
|
19
5
|
|
package/dist/webpack/mdx.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getCore
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-K7N6GD4M.js";
|
|
4
4
|
import {
|
|
5
5
|
createMdxLoader
|
|
6
|
-
} from "../chunk-
|
|
6
|
+
} from "../chunk-T6G5VOED.js";
|
|
7
7
|
import {
|
|
8
8
|
createStandaloneConfigLoader,
|
|
9
9
|
toWebpack
|
|
10
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-WAAWFNDX.js";
|
|
11
11
|
import "../chunk-4JSFLXXT.js";
|
|
12
|
-
import "../chunk-
|
|
13
|
-
import "../chunk-
|
|
12
|
+
import "../chunk-VKSHE52K.js";
|
|
13
|
+
import "../chunk-PW2AZGGD.js";
|
|
14
14
|
import "../chunk-VWJKRQZR.js";
|
|
15
15
|
|
|
16
16
|
// src/webpack/mdx.ts
|
package/dist/webpack/meta.d.ts
CHANGED
|
@@ -1,19 +1,5 @@
|
|
|
1
1
|
import { LoaderContext } from 'webpack';
|
|
2
|
-
import { W as WebpackLoaderOptions } from '../index-
|
|
3
|
-
import '../core-C3QZSdEx.js';
|
|
4
|
-
import '@mdx-js/mdx';
|
|
5
|
-
import '@standard-schema/spec';
|
|
6
|
-
import 'unified';
|
|
7
|
-
import 'fumadocs-core/mdx-plugins';
|
|
8
|
-
import 'zod';
|
|
9
|
-
import 'chokidar';
|
|
10
|
-
import 'vfile';
|
|
11
|
-
import 'fumadocs-core/source';
|
|
12
|
-
import '../runtime/types.js';
|
|
13
|
-
import 'fumadocs-core/mdx-plugins/remark-structure';
|
|
14
|
-
import 'fumadocs-core/toc';
|
|
15
|
-
import 'mdast';
|
|
16
|
-
import 'mdx/types';
|
|
2
|
+
import { W as WebpackLoaderOptions } from '../index-BqkSNsGO.js';
|
|
17
3
|
|
|
18
4
|
declare function loader(this: LoaderContext<WebpackLoaderOptions>, source: string, callback: LoaderContext<WebpackLoaderOptions>['callback']): Promise<void>;
|
|
19
5
|
|
package/dist/webpack/meta.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getCore
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-K7N6GD4M.js";
|
|
4
4
|
import {
|
|
5
5
|
createMetaLoader
|
|
6
|
-
} from "../chunk-
|
|
6
|
+
} from "../chunk-ZAYZWFWP.js";
|
|
7
7
|
import {
|
|
8
8
|
createStandaloneConfigLoader,
|
|
9
9
|
toWebpack
|
|
10
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-WAAWFNDX.js";
|
|
11
11
|
import "../chunk-4JSFLXXT.js";
|
|
12
|
-
import "../chunk-
|
|
13
|
-
import "../chunk-
|
|
12
|
+
import "../chunk-VKSHE52K.js";
|
|
13
|
+
import "../chunk-PW2AZGGD.js";
|
|
14
14
|
|
|
15
15
|
// src/webpack/meta.ts
|
|
16
16
|
var instance;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fumadocs-mdx",
|
|
3
|
-
"version": "14.0
|
|
3
|
+
"version": "14.1.0",
|
|
4
4
|
"description": "The built-in source for Fumadocs",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"NextJs",
|
|
@@ -60,10 +60,9 @@
|
|
|
60
60
|
"@mdx-js/mdx": "^3.1.1",
|
|
61
61
|
"@standard-schema/spec": "^1.0.0",
|
|
62
62
|
"chokidar": "^5.0.0",
|
|
63
|
-
"esbuild": "^0.27.
|
|
63
|
+
"esbuild": "^0.27.1",
|
|
64
64
|
"estree-util-value-to-estree": "^3.5.0",
|
|
65
65
|
"js-yaml": "^4.1.1",
|
|
66
|
-
"lru-cache": "^11.2.2",
|
|
67
66
|
"mdast-util-to-markdown": "^2.1.2",
|
|
68
67
|
"picocolors": "^1.1.1",
|
|
69
68
|
"picomatch": "^4.0.3",
|
|
@@ -74,30 +73,30 @@
|
|
|
74
73
|
"unist-util-remove-position": "^5.0.0",
|
|
75
74
|
"unist-util-visit": "^5.0.0",
|
|
76
75
|
"vfile": "^6.0.3",
|
|
77
|
-
"zod": "^4.1.
|
|
76
|
+
"zod": "^4.1.13"
|
|
78
77
|
},
|
|
79
78
|
"devDependencies": {
|
|
80
|
-
"@types/bun": "^1.3.
|
|
79
|
+
"@types/bun": "^1.3.3",
|
|
81
80
|
"@types/js-yaml": "^4.0.9",
|
|
82
81
|
"@types/mdast": "^4.0.4",
|
|
83
82
|
"@types/mdx": "^2.0.13",
|
|
84
83
|
"@types/node": "^24.10.1",
|
|
85
84
|
"@types/picomatch": "^4.0.2",
|
|
86
|
-
"@types/react": "^19.2.
|
|
87
|
-
"astro": "^5.
|
|
85
|
+
"@types/react": "^19.2.7",
|
|
86
|
+
"astro": "^5.16.4",
|
|
88
87
|
"mdast-util-directive": "^3.1.0",
|
|
89
88
|
"mdast-util-mdx-jsx": "^3.2.0",
|
|
90
|
-
"next": "16.0.
|
|
91
|
-
"react": "^19.2.
|
|
89
|
+
"next": "16.0.7",
|
|
90
|
+
"react": "^19.2.1",
|
|
92
91
|
"remark": "^15.0.1",
|
|
93
92
|
"remark-directive": "^4.0.0",
|
|
94
93
|
"remark-stringify": "^11.0.0",
|
|
95
|
-
"rollup": "^4.53.
|
|
96
|
-
"vite": "^7.2.
|
|
97
|
-
"webpack": "^5.
|
|
94
|
+
"rollup": "^4.53.3",
|
|
95
|
+
"vite": "^7.2.6",
|
|
96
|
+
"webpack": "^5.103.0",
|
|
98
97
|
"@fumadocs/mdx-remote": "1.4.3",
|
|
99
98
|
"eslint-config-custom": "0.0.0",
|
|
100
|
-
"fumadocs-core": "16.2.
|
|
99
|
+
"fumadocs-core": "16.2.3",
|
|
101
100
|
"tsconfig": "0.0.0"
|
|
102
101
|
},
|
|
103
102
|
"peerDependencies": {
|