fumadocs-mdx 11.5.2 → 11.5.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.
@@ -1,4 +1,4 @@
1
- export { b as BaseCollection, B as BaseCollectionEntry, i as DefaultMDXOptions, D as DocCollection, d as DocsCollection, F as FileInfo, G as GlobalConfig, I as InferSchema, a as InferSchemaType, M as MarkdownProps, c as MetaCollection, T as TransformContext, e as defineCollections, h as defineConfig, g as defineDocs, f as frontmatterSchema, j as getDefaultMDXOptions, m as metaSchema } from '../define-B4aTedg-.cjs';
1
+ export { a as BaseCollection, B as BaseCollectionEntry, h as DefaultMDXOptions, D as DocCollection, c as DocsCollection, F as FileInfo, G as GlobalConfig, M as MarkdownProps, b as MetaCollection, T as TransformContext, d as defineCollections, g as defineConfig, e as defineDocs, f as frontmatterSchema, i as getDefaultMDXOptions, m as metaSchema } from '../define-BUjajTka.cjs';
2
2
  import { Processor, Transformer } from 'unified';
3
3
  import { Root } from 'mdast';
4
4
  import '@mdx-js/mdx';
@@ -6,8 +6,8 @@ import 'mdx/types';
6
6
  import 'fumadocs-core/mdx-plugins';
7
7
  import 'fumadocs-core/server';
8
8
  import 'react';
9
- import '@standard-schema/spec';
10
9
  import 'zod';
10
+ import '@standard-schema/spec';
11
11
 
12
12
  declare function remarkInclude(this: Processor): Transformer<Root, Root>;
13
13
 
@@ -1,4 +1,4 @@
1
- export { b as BaseCollection, B as BaseCollectionEntry, i as DefaultMDXOptions, D as DocCollection, d as DocsCollection, F as FileInfo, G as GlobalConfig, I as InferSchema, a as InferSchemaType, M as MarkdownProps, c as MetaCollection, T as TransformContext, e as defineCollections, h as defineConfig, g as defineDocs, f as frontmatterSchema, j as getDefaultMDXOptions, m as metaSchema } from '../define-B4aTedg-.js';
1
+ export { a as BaseCollection, B as BaseCollectionEntry, h as DefaultMDXOptions, D as DocCollection, c as DocsCollection, F as FileInfo, G as GlobalConfig, M as MarkdownProps, b as MetaCollection, T as TransformContext, d as defineCollections, g as defineConfig, e as defineDocs, f as frontmatterSchema, i as getDefaultMDXOptions, m as metaSchema } from '../define-BUjajTka.js';
2
2
  import { Processor, Transformer } from 'unified';
3
3
  import { Root } from 'mdast';
4
4
  import '@mdx-js/mdx';
@@ -6,8 +6,8 @@ import 'mdx/types';
6
6
  import 'fumadocs-core/mdx-plugins';
7
7
  import 'fumadocs-core/server';
8
8
  import 'react';
9
- import '@standard-schema/spec';
10
9
  import 'zod';
10
+ import '@standard-schema/spec';
11
11
 
12
12
  declare function remarkInclude(this: Processor): Transformer<Root, Root>;
13
13
 
@@ -5,8 +5,8 @@ import { StructuredData } from 'fumadocs-core/mdx-plugins';
5
5
  import { TableOfContents } from 'fumadocs-core/server';
6
6
  import { Pluggable } from 'unified';
7
7
  import { FC } from 'react';
8
- import { StandardSchemaV1 } from '@standard-schema/spec';
9
8
  import { z } from 'zod';
9
+ import { StandardSchemaV1 } from '@standard-schema/spec';
10
10
 
11
11
  type ResolvePlugins = Pluggable[] | ((v: Pluggable[]) => Pluggable[]);
12
12
  type DefaultMDXOptions = Omit<NonNullable<ProcessorOptions>, 'rehypePlugins' | 'remarkPlugins' | '_ctx'> & {
@@ -42,12 +42,6 @@ interface GlobalConfig {
42
42
  */
43
43
  generateManifest?: boolean;
44
44
  }
45
- type InferSchema<CollectionOut> = CollectionOut extends {
46
- _type: {
47
- schema: infer T;
48
- };
49
- } ? T : never;
50
- type InferSchemaType<C> = InferSchema<C> extends StandardSchemaV1 ? StandardSchemaV1.InferOutput<InferSchema<C>> : never;
51
45
  interface FileInfo {
52
46
  path: string;
53
47
  absolutePath: string;
@@ -205,9 +199,10 @@ declare function defineDocs<DocSchema extends StandardSchemaV1 = typeof frontmat
205
199
  type: 'meta';
206
200
  _type: {
207
201
  schema: MetaSchema;
202
+ async: false;
208
203
  };
209
204
  };
210
205
  };
211
206
  declare function defineConfig(config?: GlobalConfig): GlobalConfig;
212
207
 
213
- export { type BaseCollectionEntry as B, type DocCollection as D, type FileInfo as F, type GlobalConfig as G, type InferSchema as I, type MarkdownProps as M, type TransformContext as T, type InferSchemaType as a, type BaseCollection as b, type MetaCollection as c, type DocsCollection as d, defineCollections as e, frontmatterSchema as f, defineDocs as g, defineConfig as h, type DefaultMDXOptions as i, getDefaultMDXOptions as j, metaSchema as m };
208
+ export { type BaseCollectionEntry as B, type DocCollection as D, type FileInfo as F, type GlobalConfig as G, type MarkdownProps as M, type TransformContext as T, type BaseCollection as a, type MetaCollection as b, type DocsCollection as c, defineCollections as d, defineDocs as e, frontmatterSchema as f, defineConfig as g, type DefaultMDXOptions as h, getDefaultMDXOptions as i, metaSchema as m };
@@ -5,8 +5,8 @@ import { StructuredData } from 'fumadocs-core/mdx-plugins';
5
5
  import { TableOfContents } from 'fumadocs-core/server';
6
6
  import { Pluggable } from 'unified';
7
7
  import { FC } from 'react';
8
- import { StandardSchemaV1 } from '@standard-schema/spec';
9
8
  import { z } from 'zod';
9
+ import { StandardSchemaV1 } from '@standard-schema/spec';
10
10
 
11
11
  type ResolvePlugins = Pluggable[] | ((v: Pluggable[]) => Pluggable[]);
12
12
  type DefaultMDXOptions = Omit<NonNullable<ProcessorOptions>, 'rehypePlugins' | 'remarkPlugins' | '_ctx'> & {
@@ -42,12 +42,6 @@ interface GlobalConfig {
42
42
  */
43
43
  generateManifest?: boolean;
44
44
  }
45
- type InferSchema<CollectionOut> = CollectionOut extends {
46
- _type: {
47
- schema: infer T;
48
- };
49
- } ? T : never;
50
- type InferSchemaType<C> = InferSchema<C> extends StandardSchemaV1 ? StandardSchemaV1.InferOutput<InferSchema<C>> : never;
51
45
  interface FileInfo {
52
46
  path: string;
53
47
  absolutePath: string;
@@ -205,9 +199,10 @@ declare function defineDocs<DocSchema extends StandardSchemaV1 = typeof frontmat
205
199
  type: 'meta';
206
200
  _type: {
207
201
  schema: MetaSchema;
202
+ async: false;
208
203
  };
209
204
  };
210
205
  };
211
206
  declare function defineConfig(config?: GlobalConfig): GlobalConfig;
212
207
 
213
- export { type BaseCollectionEntry as B, type DocCollection as D, type FileInfo as F, type GlobalConfig as G, type InferSchema as I, type MarkdownProps as M, type TransformContext as T, type InferSchemaType as a, type BaseCollection as b, type MetaCollection as c, type DocsCollection as d, defineCollections as e, frontmatterSchema as f, defineDocs as g, defineConfig as h, type DefaultMDXOptions as i, getDefaultMDXOptions as j, metaSchema as m };
208
+ export { type BaseCollectionEntry as B, type DocCollection as D, type FileInfo as F, type GlobalConfig as G, type MarkdownProps as M, type TransformContext as T, type BaseCollection as a, type MetaCollection as b, type DocsCollection as c, defineCollections as d, defineDocs as e, frontmatterSchema as f, defineConfig as g, type DefaultMDXOptions as h, getDefaultMDXOptions as i, metaSchema as m };
package/dist/index.d.cts CHANGED
@@ -1,15 +1,15 @@
1
1
  import { PageData, MetaData, Source, VirtualFile } from 'fumadocs-core/source';
2
- import { B as BaseCollectionEntry } from './define-B4aTedg-.cjs';
3
- import { R as Runtime } from './types-C214DTNR.cjs';
4
- export { a as RuntimeFile } from './types-C214DTNR.cjs';
2
+ import { B as BaseCollectionEntry } from './define-BUjajTka.cjs';
3
+ import { R as Runtime } from './types-Dh6jLIT1.cjs';
4
+ export { a as RuntimeFile } from './types-Dh6jLIT1.cjs';
5
5
  import '@mdx-js/mdx';
6
6
  import 'mdx/types';
7
7
  import 'fumadocs-core/mdx-plugins';
8
8
  import 'fumadocs-core/server';
9
9
  import 'unified';
10
10
  import 'react';
11
- import '@standard-schema/spec';
12
11
  import 'zod';
12
+ import '@standard-schema/spec';
13
13
 
14
14
  declare const _runtime: Runtime;
15
15
  declare function createMDXSource<Doc extends PageData & BaseCollectionEntry, Meta extends MetaData & BaseCollectionEntry>(docs: Doc[], meta?: Meta[]): Source<{
package/dist/index.d.ts CHANGED
@@ -1,15 +1,15 @@
1
1
  import { PageData, MetaData, Source, VirtualFile } from 'fumadocs-core/source';
2
- import { B as BaseCollectionEntry } from './define-B4aTedg-.js';
3
- import { R as Runtime } from './types-qPYo6njm.js';
4
- export { a as RuntimeFile } from './types-qPYo6njm.js';
2
+ import { B as BaseCollectionEntry } from './define-BUjajTka.js';
3
+ import { R as Runtime } from './types-CvzwQDWV.js';
4
+ export { a as RuntimeFile } from './types-CvzwQDWV.js';
5
5
  import '@mdx-js/mdx';
6
6
  import 'mdx/types';
7
7
  import 'fumadocs-core/mdx-plugins';
8
8
  import 'fumadocs-core/server';
9
9
  import 'unified';
10
10
  import 'react';
11
- import '@standard-schema/spec';
12
11
  import 'zod';
12
+ import '@standard-schema/spec';
13
13
 
14
14
  declare const _runtime: Runtime;
15
15
  declare function createMDXSource<Doc extends PageData & BaseCollectionEntry, Meta extends MetaData & BaseCollectionEntry>(docs: Doc[], meta?: Meta[]): Source<{
@@ -1,13 +1,13 @@
1
- import { L as LoadedConfig, b as RuntimeAsync } from '../types-C214DTNR.cjs';
2
- import '../define-B4aTedg-.cjs';
1
+ import { L as LoadedConfig, b as RuntimeAsync } from '../types-Dh6jLIT1.cjs';
2
+ import '../define-BUjajTka.cjs';
3
3
  import '@mdx-js/mdx';
4
4
  import 'mdx/types';
5
5
  import 'fumadocs-core/mdx-plugins';
6
6
  import 'fumadocs-core/server';
7
7
  import 'unified';
8
8
  import 'react';
9
- import '@standard-schema/spec';
10
9
  import 'zod';
10
+ import '@standard-schema/spec';
11
11
  import 'fumadocs-core/source';
12
12
 
13
13
  declare function buildConfig(config: Record<string, unknown>): [err: string, value: null] | [err: null, value: LoadedConfig];
@@ -1,13 +1,13 @@
1
- import { L as LoadedConfig, b as RuntimeAsync } from '../types-qPYo6njm.js';
2
- import '../define-B4aTedg-.js';
1
+ import { L as LoadedConfig, b as RuntimeAsync } from '../types-CvzwQDWV.js';
2
+ import '../define-BUjajTka.js';
3
3
  import '@mdx-js/mdx';
4
4
  import 'mdx/types';
5
5
  import 'fumadocs-core/mdx-plugins';
6
6
  import 'fumadocs-core/server';
7
7
  import 'unified';
8
8
  import 'react';
9
- import '@standard-schema/spec';
10
9
  import 'zod';
10
+ import '@standard-schema/spec';
11
11
  import 'fumadocs-core/source';
12
12
 
13
13
  declare function buildConfig(config: Record<string, unknown>): [err: string, value: null] | [err: null, value: LoadedConfig];
@@ -1,4 +1,4 @@
1
- import { D as DocCollection, c as MetaCollection, d as DocsCollection, G as GlobalConfig, F as FileInfo, M as MarkdownProps, B as BaseCollectionEntry } from './define-B4aTedg-.js';
1
+ import { D as DocCollection, b as MetaCollection, c as DocsCollection, G as GlobalConfig, F as FileInfo, M as MarkdownProps, B as BaseCollectionEntry } from './define-BUjajTka.js';
2
2
  import { StandardSchemaV1 } from '@standard-schema/spec';
3
3
  import { Source, PageData, MetaData } from 'fumadocs-core/source';
4
4
  import { ProcessorOptions } from '@mdx-js/mdx';
@@ -34,7 +34,7 @@ interface Runtime {
34
34
  schema: infer Schema extends StandardSchemaV1;
35
35
  };
36
36
  } ? MetaOut<Schema>[] : never;
37
- docs: <Docs>(docs: RuntimeFile[], metas: RuntimeFile[]) => Docs extends {
37
+ docs: <C>(docs: RuntimeFile[], metas: RuntimeFile[]) => C extends {
38
38
  type: 'docs';
39
39
  docs: {
40
40
  type: 'doc';
@@ -67,7 +67,7 @@ interface RuntimeAsync {
67
67
  schema: infer Schema extends StandardSchemaV1;
68
68
  };
69
69
  } ? AsyncDocOut<Schema>[] : never;
70
- docs: <Docs>(docs: RuntimeFile[], metas: RuntimeFile[], collection: string, config: LoadedConfig) => Docs extends {
70
+ docs: <C>(docs: RuntimeFile[], metas: RuntimeFile[], collection: string, config: LoadedConfig) => C extends {
71
71
  type: 'docs';
72
72
  docs: {
73
73
  type: 'doc';
@@ -1,4 +1,4 @@
1
- import { D as DocCollection, c as MetaCollection, d as DocsCollection, G as GlobalConfig, F as FileInfo, M as MarkdownProps, B as BaseCollectionEntry } from './define-B4aTedg-.cjs';
1
+ import { D as DocCollection, b as MetaCollection, c as DocsCollection, G as GlobalConfig, F as FileInfo, M as MarkdownProps, B as BaseCollectionEntry } from './define-BUjajTka.cjs';
2
2
  import { StandardSchemaV1 } from '@standard-schema/spec';
3
3
  import { Source, PageData, MetaData } from 'fumadocs-core/source';
4
4
  import { ProcessorOptions } from '@mdx-js/mdx';
@@ -34,7 +34,7 @@ interface Runtime {
34
34
  schema: infer Schema extends StandardSchemaV1;
35
35
  };
36
36
  } ? MetaOut<Schema>[] : never;
37
- docs: <Docs>(docs: RuntimeFile[], metas: RuntimeFile[]) => Docs extends {
37
+ docs: <C>(docs: RuntimeFile[], metas: RuntimeFile[]) => C extends {
38
38
  type: 'docs';
39
39
  docs: {
40
40
  type: 'doc';
@@ -67,7 +67,7 @@ interface RuntimeAsync {
67
67
  schema: infer Schema extends StandardSchemaV1;
68
68
  };
69
69
  } ? AsyncDocOut<Schema>[] : never;
70
- docs: <Docs>(docs: RuntimeFile[], metas: RuntimeFile[], collection: string, config: LoadedConfig) => Docs extends {
70
+ docs: <C>(docs: RuntimeFile[], metas: RuntimeFile[], collection: string, config: LoadedConfig) => C extends {
71
71
  type: 'docs';
72
72
  docs: {
73
73
  type: 'doc';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fumadocs-mdx",
3
- "version": "11.5.2",
3
+ "version": "11.5.3",
4
4
  "description": "The built-in source for Fumadocs",
5
5
  "keywords": [
6
6
  "NextJs",
@@ -43,22 +43,20 @@
43
43
  ],
44
44
  "dependencies": {
45
45
  "@mdx-js/mdx": "^3.1.0",
46
+ "@standard-schema/spec": "^1.0.0",
46
47
  "chokidar": "^4.0.3",
47
48
  "cross-spawn": "^7.0.6",
48
49
  "esbuild": "^0.24.2",
49
50
  "estree-util-value-to-estree": "^3.3.2",
50
51
  "fast-glob": "^3.3.3",
51
52
  "gray-matter": "^4.0.3",
52
- "micromatch": "^4.0.8",
53
53
  "unist-util-visit": "^5.0.0",
54
54
  "zod": "^3.24.1"
55
55
  },
56
56
  "devDependencies": {
57
- "@standard-schema/spec": "^1.0.0",
58
57
  "@types/cross-spawn": "^6.0.6",
59
58
  "@types/mdast": "^4.0.3",
60
59
  "@types/mdx": "^2.0.13",
61
- "@types/micromatch": "^4.0.9",
62
60
  "@types/react": "^19.0.8",
63
61
  "mdast-util-mdx-jsx": "^3.2.0",
64
62
  "next": "^15.1.6",
@@ -66,9 +64,9 @@
66
64
  "vfile": "^6.0.3",
67
65
  "webpack": "^5.97.1",
68
66
  "@fumadocs/mdx-remote": "1.2.0",
69
- "eslint-config-custom": "0.0.0",
67
+ "tsconfig": "0.0.0",
70
68
  "fumadocs-core": "15.0.5",
71
- "tsconfig": "0.0.0"
69
+ "eslint-config-custom": "0.0.0"
72
70
  },
73
71
  "peerDependencies": {
74
72
  "@fumadocs/mdx-remote": "^1.2.0",