@@ -17,41 +17,45 @@ export type ValidationLevel =
1717 * Configuration options for the Markdoc preprocessor
1818 */
1919export interface Options {
20+ /**
21+ * Enable adding Markdown comments to your documents.
22+ * @default true
23+ */
24+ comments ?: boolean ;
25+ /**
26+ * Specify a directory to import Svelte components to customize Markdoc Nodes and Tags.
27+ * Use import paths and aliases that Svelte can resolve.
28+ * @default "$lib/components"
29+ */
30+ components ?: string ;
2031 /**
2132 * File extensions to preprocess.
2233 * @default [".mdoc", ".md"]
2334 */
2435 extensions ?: string [ ] ;
2536 /**
26- * Specify a directory to import folders or files to use as Markdoc Schemas.
27- * Path is relative to Svelte project root.
28- * @default ["./markdoc", "./src/markdoc"]
29- */
30- schema ?: string ;
31- /**
32- * Import an object of nodes to use as Markdoc Nodes.
33- * Overwrites nodes with the same name from 'schema' directory.
37+ * Import an object of functions to use as Markdoc Functions.
38+ * Overwrites functions with the same name from 'schema' directory.
3439 * @default undefined
3540 */
36- nodes ?: Config [ "nodes " ] ;
41+ functions ?: Config [ "functions " ] ;
3742 /**
38- * Import an object of tags to use as Markdoc Tags .
39- * Overwrites tags with the same name from 'schema' directory .
43+ * Specify a Svelte component to use as a layout for the Markdoc file .
44+ * Use import paths and aliases that Svelte can resolve .
4045 * @default undefined
4146 */
42- tags ?: Config [ "tags" ] ;
47+ layout ?: string ;
4348 /**
44- * Import an object of variables to use as Markdoc Variables.
45- * Overwrites variables with the same name from 'schema' directory.
46- * @default undefined
49+ * Enable autoconvert URL-like text to links.
50+ * @default false
4751 */
48- variables ?: Config [ "variables" ] ;
52+ linkify ?: boolean ;
4953 /**
50- * Import an object of functions to use as Markdoc Functions .
51- * Overwrites functions with the same name from 'schema' directory.
54+ * Import an object of nodes to use as Markdoc Nodes .
55+ * Overwrites nodes with the same name from 'schema' directory.
5256 * @default undefined
5357 */
54- functions ?: Config [ "functions " ] ;
58+ nodes ?: Config [ "nodes " ] ;
5559 /**
5660 * Specify a directory to import files with 'extensions' as Markdoc Partials.
5761 * Default is to load partials from 'schema' directory.
@@ -61,27 +65,17 @@ export interface Options {
6165 */
6266 partials ?: string ;
6367 /**
64- * Specify a directory to import Svelte components to customize Markdoc Nodes and Tags .
65- * Use import paths and aliases that Svelte can resolve .
66- * @default "$lib/components"
68+ * Specify a directory to import folders or files to use as Markdoc Schemas .
69+ * Path is relative to Svelte project root .
70+ * @default ["./markdoc", "./src/markdoc"]
6771 */
68- components ?: string ;
72+ schema ?: string ;
6973 /**
70- * Specify a Svelte component to use as a layout for the Markdoc file .
71- * Use import paths and aliases that Svelte can resolve .
74+ * Import an object of tags to use as Markdoc Tags .
75+ * Overwrites tags with the same name from 'schema' directory .
7276 * @default undefined
7377 */
74- layout ?: string ;
75- /**
76- * Enable adding Markdown comments to your documents.
77- * @default true
78- */
79- comments ?: boolean ;
80- /**
81- * Enable autoconvert URL-like text to links.
82- * @default false
83- */
84- linkify ?: boolean ;
78+ tags ?: Config [ "tags" ] ;
8579 /**
8680 * Enable some language-neutral replacement + quotes beautification.
8781 * @default false
@@ -92,6 +86,12 @@ export interface Options {
9286 * @default "error"
9387 */
9488 validationLevel ?: ValidationLevel ;
89+ /**
90+ * Import an object of variables to use as Markdoc Variables.
91+ * Overwrites variables with the same name from 'schema' directory.
92+ * @default undefined
93+ */
94+ variables ?: Config [ "variables" ] ;
9595}
9696
9797/**
0 commit comments