@storybook/addon-docs 9.0.0-alpha.9 → 9.0.0-beta.1
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/README.md +1 -1
- package/angular/index.js +0 -2
- package/dist/Color-SIUCOEKT.mjs +10 -0
- package/dist/DocsRenderer-3PZUHFFL.mjs +2 -0
- package/dist/blocks.d.ts +1031 -2
- package/dist/blocks.js +195 -1
- package/dist/blocks.mjs +211 -3
- package/dist/{chunk-PRSJUHPQ.mjs → chunk-GFTNOJSG.mjs} +2 -2
- package/dist/{chunk-NUUEMKO5.mjs → chunk-GWJYCGSQ.mjs} +1 -1
- package/dist/chunk-QUZPS4B6.mjs +3 -0
- package/dist/chunk-W6FI2KYE.mjs +3 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +4 -4
- package/dist/mdx-loader.d.ts +1676 -97
- package/dist/mdx-loader.js +11 -11
- package/dist/mdx-loader.mjs +11 -11
- package/dist/preset.js +13 -13
- package/dist/preview.js +1 -1
- package/dist/preview.mjs +2 -2
- package/ember/index.js +0 -2
- package/package.json +17 -8
- package/dist/DocsRenderer-CFRXHY34.mjs +0 -2
- package/dist/chunk-H6MOWX77.mjs +0 -3
- package/dist/manager.d.ts +0 -2
- package/dist/manager.js +0 -1
- package/dist/manager.mjs +0 -8
package/dist/mdx-loader.d.ts
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { transformAsync } from '@babel/core';
|
|
2
2
|
import * as unist from 'unist';
|
|
3
|
-
import { Node as Node$2, Point as Point$2, Position as Position$2, Data as Data$
|
|
3
|
+
import { Node as Node$2, Point as Point$2, Position as Position$2, Data as Data$7 } from 'unist';
|
|
4
4
|
import * as hast from 'hast';
|
|
5
|
-
import { ElementContent as ElementContent$1, Properties, Literal, Data as Data$
|
|
5
|
+
import { ElementContent as ElementContent$1, Properties, Literal, Data as Data$5, Parent as Parent$1 } from 'hast';
|
|
6
6
|
import * as mdast from 'mdast';
|
|
7
|
-
import { Parent, BlockContent, DefinitionContent, Data as Data$
|
|
7
|
+
import { Parent, BlockContent, DefinitionContent, Data as Data$6, PhrasingContent, Literal as Literal$1 } from 'mdast';
|
|
8
8
|
import { Program } from 'estree-jsx';
|
|
9
9
|
|
|
10
10
|
/**
|
|
11
11
|
* Message.
|
|
12
12
|
*/
|
|
13
13
|
declare class VFileMessage extends Error {
|
|
14
|
-
constructor(reason: string, options?: Options$
|
|
14
|
+
constructor(reason: string, options?: Options$6 | null | undefined)
|
|
15
15
|
constructor(
|
|
16
16
|
reason: string,
|
|
17
|
-
parent: Node$1 | NodeLike$
|
|
17
|
+
parent: Node$1 | NodeLike$2 | null | undefined,
|
|
18
18
|
origin?: string | null | undefined
|
|
19
19
|
)
|
|
20
20
|
constructor(
|
|
@@ -25,7 +25,7 @@ declare class VFileMessage extends Error {
|
|
|
25
25
|
constructor(reason: string, origin?: string | null | undefined)
|
|
26
26
|
constructor(
|
|
27
27
|
cause: Error | VFileMessage,
|
|
28
|
-
parent: Node$1 | NodeLike$
|
|
28
|
+
parent: Node$1 | NodeLike$2 | null | undefined,
|
|
29
29
|
origin?: string | null | undefined
|
|
30
30
|
)
|
|
31
31
|
constructor(
|
|
@@ -124,14 +124,14 @@ declare class VFileMessage extends Error {
|
|
|
124
124
|
type Node$1 = unist.Node
|
|
125
125
|
type Point$1 = unist.Point
|
|
126
126
|
type Position$1 = unist.Position
|
|
127
|
-
type NodeLike$
|
|
127
|
+
type NodeLike$2 = object & {
|
|
128
128
|
type: string
|
|
129
129
|
position?: Position$1 | undefined
|
|
130
130
|
}
|
|
131
131
|
/**
|
|
132
132
|
* Configuration.
|
|
133
133
|
*/
|
|
134
|
-
type Options$
|
|
134
|
+
type Options$6 = {
|
|
135
135
|
/**
|
|
136
136
|
* Stack of (inclusive) ancestor nodes surrounding the message (optional).
|
|
137
137
|
*/
|
|
@@ -154,9 +154,9 @@ type Options$5 = {
|
|
|
154
154
|
source?: string | null | undefined
|
|
155
155
|
}
|
|
156
156
|
|
|
157
|
-
type Options$
|
|
157
|
+
type Options$5 = Options$6
|
|
158
158
|
|
|
159
|
-
declare class VFile$
|
|
159
|
+
declare class VFile$2 {
|
|
160
160
|
/**
|
|
161
161
|
* Create a new virtual file.
|
|
162
162
|
*
|
|
@@ -179,7 +179,7 @@ declare class VFile$1 {
|
|
|
179
179
|
* @returns
|
|
180
180
|
* New instance.
|
|
181
181
|
*/
|
|
182
|
-
constructor(value?: Compatible$
|
|
182
|
+
constructor(value?: Compatible$3 | null | undefined);
|
|
183
183
|
/**
|
|
184
184
|
* Base of `path` (default: `process.cwd()` or `'/'` in browsers).
|
|
185
185
|
*
|
|
@@ -194,7 +194,7 @@ declare class VFile$1 {
|
|
|
194
194
|
*
|
|
195
195
|
* @type {Data}
|
|
196
196
|
*/
|
|
197
|
-
data: Data$
|
|
197
|
+
data: Data$4;
|
|
198
198
|
/**
|
|
199
199
|
* List of file paths the file moved between.
|
|
200
200
|
*
|
|
@@ -214,7 +214,7 @@ declare class VFile$1 {
|
|
|
214
214
|
*
|
|
215
215
|
* @type {Value}
|
|
216
216
|
*/
|
|
217
|
-
value: Value$
|
|
217
|
+
value: Value$2;
|
|
218
218
|
/**
|
|
219
219
|
* Source map.
|
|
220
220
|
*
|
|
@@ -223,7 +223,7 @@ declare class VFile$1 {
|
|
|
223
223
|
*
|
|
224
224
|
* @type {Map | null | undefined}
|
|
225
225
|
*/
|
|
226
|
-
map: Map$
|
|
226
|
+
map: Map$2 | null | undefined;
|
|
227
227
|
/**
|
|
228
228
|
* Custom, non-string, compiled, representation.
|
|
229
229
|
*
|
|
@@ -399,7 +399,7 @@ declare class VFile$1 {
|
|
|
399
399
|
* @throws {VFileMessage}
|
|
400
400
|
* Message.
|
|
401
401
|
*/
|
|
402
|
-
fail(reason: string, options?: Options$
|
|
402
|
+
fail(reason: string, options?: Options$5 | null | undefined): never;
|
|
403
403
|
/**
|
|
404
404
|
* Create a fatal message for `reason` associated with the file.
|
|
405
405
|
*
|
|
@@ -460,7 +460,7 @@ declare class VFile$1 {
|
|
|
460
460
|
* @throws {VFileMessage}
|
|
461
461
|
* Message.
|
|
462
462
|
*/
|
|
463
|
-
fail(reason: string, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): never;
|
|
463
|
+
fail(reason: string, parent: Node$2 | NodeLike$1 | null | undefined, origin?: string | null | undefined): never;
|
|
464
464
|
/**
|
|
465
465
|
* Create a fatal message for `reason` associated with the file.
|
|
466
466
|
*
|
|
@@ -643,7 +643,7 @@ declare class VFile$1 {
|
|
|
643
643
|
* @throws {VFileMessage}
|
|
644
644
|
* Message.
|
|
645
645
|
*/
|
|
646
|
-
fail(cause: Error | VFileMessage, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): never;
|
|
646
|
+
fail(cause: Error | VFileMessage, parent: Node$2 | NodeLike$1 | null | undefined, origin?: string | null | undefined): never;
|
|
647
647
|
/**
|
|
648
648
|
* Create a fatal message for `reason` associated with the file.
|
|
649
649
|
*
|
|
@@ -824,7 +824,7 @@ declare class VFile$1 {
|
|
|
824
824
|
* @returns {VFileMessage}
|
|
825
825
|
* Message.
|
|
826
826
|
*/
|
|
827
|
-
info(reason: string, options?: Options$
|
|
827
|
+
info(reason: string, options?: Options$5 | null | undefined): VFileMessage;
|
|
828
828
|
/**
|
|
829
829
|
* Create an info message for `reason` associated with the file.
|
|
830
830
|
*
|
|
@@ -883,7 +883,7 @@ declare class VFile$1 {
|
|
|
883
883
|
* @returns {VFileMessage}
|
|
884
884
|
* Message.
|
|
885
885
|
*/
|
|
886
|
-
info(reason: string, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
886
|
+
info(reason: string, parent: Node$2 | NodeLike$1 | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
887
887
|
/**
|
|
888
888
|
* Create an info message for `reason` associated with the file.
|
|
889
889
|
*
|
|
@@ -1060,7 +1060,7 @@ declare class VFile$1 {
|
|
|
1060
1060
|
* @returns {VFileMessage}
|
|
1061
1061
|
* Message.
|
|
1062
1062
|
*/
|
|
1063
|
-
info(cause: Error | VFileMessage, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
1063
|
+
info(cause: Error | VFileMessage, parent: Node$2 | NodeLike$1 | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
1064
1064
|
/**
|
|
1065
1065
|
* Create an info message for `reason` associated with the file.
|
|
1066
1066
|
*
|
|
@@ -1237,7 +1237,7 @@ declare class VFile$1 {
|
|
|
1237
1237
|
* @returns {VFileMessage}
|
|
1238
1238
|
* Message.
|
|
1239
1239
|
*/
|
|
1240
|
-
message(reason: string, options?: Options$
|
|
1240
|
+
message(reason: string, options?: Options$5 | null | undefined): VFileMessage;
|
|
1241
1241
|
/**
|
|
1242
1242
|
* Create a message for `reason` associated with the file.
|
|
1243
1243
|
*
|
|
@@ -1296,7 +1296,7 @@ declare class VFile$1 {
|
|
|
1296
1296
|
* @returns {VFileMessage}
|
|
1297
1297
|
* Message.
|
|
1298
1298
|
*/
|
|
1299
|
-
message(reason: string, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
1299
|
+
message(reason: string, parent: Node$2 | NodeLike$1 | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
1300
1300
|
/**
|
|
1301
1301
|
* Create a message for `reason` associated with the file.
|
|
1302
1302
|
*
|
|
@@ -1473,7 +1473,7 @@ declare class VFile$1 {
|
|
|
1473
1473
|
* @returns {VFileMessage}
|
|
1474
1474
|
* Message.
|
|
1475
1475
|
*/
|
|
1476
|
-
message(cause: Error | VFileMessage, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
1476
|
+
message(cause: Error | VFileMessage, parent: Node$2 | NodeLike$1 | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
1477
1477
|
/**
|
|
1478
1478
|
* Create a message for `reason` associated with the file.
|
|
1479
1479
|
*
|
|
@@ -1607,19 +1607,19 @@ declare class VFile$1 {
|
|
|
1607
1607
|
*/
|
|
1608
1608
|
toString(encoding?: string | null | undefined): string;
|
|
1609
1609
|
}
|
|
1610
|
-
type NodeLike = object & {
|
|
1610
|
+
type NodeLike$1 = object & {
|
|
1611
1611
|
type: string;
|
|
1612
1612
|
position?: Position$2 | undefined;
|
|
1613
1613
|
};
|
|
1614
1614
|
|
|
1615
1615
|
// See: <https://github.com/sindresorhus/type-fest/blob/main/source/empty-object.d.ts>
|
|
1616
|
-
declare const emptyObjectSymbol$
|
|
1616
|
+
declare const emptyObjectSymbol$3: unique symbol
|
|
1617
1617
|
|
|
1618
1618
|
|
|
1619
1619
|
/**
|
|
1620
1620
|
* Things that can be passed to the constructor.
|
|
1621
1621
|
*/
|
|
1622
|
-
type Compatible$
|
|
1622
|
+
type Compatible$3 = Options$4 | URL | VFile$2 | Value$2
|
|
1623
1623
|
|
|
1624
1624
|
/**
|
|
1625
1625
|
* Raw source map.
|
|
@@ -1627,7 +1627,7 @@ type Compatible$2 = Options$3 | URL | VFile$1 | Value$1
|
|
|
1627
1627
|
* See:
|
|
1628
1628
|
* <https://github.com/mozilla/source-map/blob/60adcb0/source-map.d.ts#L15-L23>.
|
|
1629
1629
|
*/
|
|
1630
|
-
interface Map$
|
|
1630
|
+
interface Map$2 {
|
|
1631
1631
|
/**
|
|
1632
1632
|
* The generated file this source map is associated with.
|
|
1633
1633
|
*/
|
|
@@ -1671,8 +1671,8 @@ interface Map$1 {
|
|
|
1671
1671
|
* }
|
|
1672
1672
|
* }
|
|
1673
1673
|
*/
|
|
1674
|
-
interface DataMap {
|
|
1675
|
-
[emptyObjectSymbol$
|
|
1674
|
+
interface DataMap$1 {
|
|
1675
|
+
[emptyObjectSymbol$3]?: never
|
|
1676
1676
|
}
|
|
1677
1677
|
|
|
1678
1678
|
/**
|
|
@@ -1680,12 +1680,12 @@ interface DataMap {
|
|
|
1680
1680
|
*
|
|
1681
1681
|
* Known attributes can be added to {@linkcode DataMap}
|
|
1682
1682
|
*/
|
|
1683
|
-
type Data$
|
|
1683
|
+
type Data$4 = Record<string, unknown> & Partial<DataMap$1>
|
|
1684
1684
|
|
|
1685
1685
|
/**
|
|
1686
1686
|
* Configuration.
|
|
1687
1687
|
*/
|
|
1688
|
-
interface Options$
|
|
1688
|
+
interface Options$4 {
|
|
1689
1689
|
/**
|
|
1690
1690
|
* Arbitrary fields that will be shallow copied over to the new file.
|
|
1691
1691
|
*/
|
|
@@ -1701,7 +1701,7 @@ interface Options$3 {
|
|
|
1701
1701
|
/**
|
|
1702
1702
|
* Set `data` (associated info).
|
|
1703
1703
|
*/
|
|
1704
|
-
data?: Data$
|
|
1704
|
+
data?: Data$4 | null | undefined
|
|
1705
1705
|
/**
|
|
1706
1706
|
* Set `dirname` (path w/o basename).
|
|
1707
1707
|
*/
|
|
@@ -1725,7 +1725,7 @@ interface Options$3 {
|
|
|
1725
1725
|
/**
|
|
1726
1726
|
* Set `value` (the contents of the file).
|
|
1727
1727
|
*/
|
|
1728
|
-
value?: Value$
|
|
1728
|
+
value?: Value$2 | null | undefined
|
|
1729
1729
|
}
|
|
1730
1730
|
|
|
1731
1731
|
/**
|
|
@@ -1733,10 +1733,10 @@ interface Options$3 {
|
|
|
1733
1733
|
*
|
|
1734
1734
|
* Can either be text or a `Uint8Array` structure.
|
|
1735
1735
|
*/
|
|
1736
|
-
type Value$
|
|
1736
|
+
type Value$2 = Uint8Array | string
|
|
1737
1737
|
|
|
1738
1738
|
// See: <https://github.com/sindresorhus/type-fest/blob/main/source/empty-object.d.ts>
|
|
1739
|
-
declare const emptyObjectSymbol$
|
|
1739
|
+
declare const emptyObjectSymbol$2: unique symbol
|
|
1740
1740
|
|
|
1741
1741
|
/**
|
|
1742
1742
|
* Interface of known results from compilers.
|
|
@@ -1786,7 +1786,7 @@ interface CompileResultMap$1 {
|
|
|
1786
1786
|
* export {} // You may not need this, but it makes sure the file is a module.
|
|
1787
1787
|
* ```
|
|
1788
1788
|
*/
|
|
1789
|
-
interface Data$
|
|
1789
|
+
interface Data$3 {
|
|
1790
1790
|
settings?: Settings$2 | undefined
|
|
1791
1791
|
}
|
|
1792
1792
|
|
|
@@ -1815,7 +1815,7 @@ interface Data$2 {
|
|
|
1815
1815
|
* ```
|
|
1816
1816
|
*/
|
|
1817
1817
|
interface Settings$2 {
|
|
1818
|
-
[emptyObjectSymbol$
|
|
1818
|
+
[emptyObjectSymbol$2]?: never
|
|
1819
1819
|
}
|
|
1820
1820
|
|
|
1821
1821
|
type Middleware = (...input: Array<any>) => any
|
|
@@ -1923,7 +1923,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
1923
1923
|
* This is a private internal property and should not be used.
|
|
1924
1924
|
* @type {Data}
|
|
1925
1925
|
*/
|
|
1926
|
-
namespace: Data$
|
|
1926
|
+
namespace: Data$2;
|
|
1927
1927
|
/**
|
|
1928
1928
|
* Parser to use.
|
|
1929
1929
|
*
|
|
@@ -2012,7 +2012,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2012
2012
|
* The current processor when setting, the value at `key` when getting, or
|
|
2013
2013
|
* the entire dataset when getting without key.
|
|
2014
2014
|
*/
|
|
2015
|
-
data<Key extends keyof Data>(): Data$
|
|
2015
|
+
data<Key extends keyof Data$1>(): Data$2;
|
|
2016
2016
|
/**
|
|
2017
2017
|
* Configure the processor with info available to all plugins.
|
|
2018
2018
|
* Information is stored in an object.
|
|
@@ -2072,7 +2072,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2072
2072
|
* The current processor when setting, the value at `key` when getting, or
|
|
2073
2073
|
* the entire dataset when getting without key.
|
|
2074
2074
|
*/
|
|
2075
|
-
data<Key extends keyof Data>(dataset: Data$
|
|
2075
|
+
data<Key extends keyof Data$1>(dataset: Data$2): Processor<ParseTree, HeadTree, TailTree, CompileTree, CompileResult>;
|
|
2076
2076
|
/**
|
|
2077
2077
|
* Configure the processor with info available to all plugins.
|
|
2078
2078
|
* Information is stored in an object.
|
|
@@ -2132,7 +2132,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2132
2132
|
* The current processor when setting, the value at `key` when getting, or
|
|
2133
2133
|
* the entire dataset when getting without key.
|
|
2134
2134
|
*/
|
|
2135
|
-
data<Key extends keyof Data>(key: Key): Data[Key];
|
|
2135
|
+
data<Key extends keyof Data$1>(key: Key): Data$1[Key];
|
|
2136
2136
|
/**
|
|
2137
2137
|
* Configure the processor with info available to all plugins.
|
|
2138
2138
|
* Information is stored in an object.
|
|
@@ -2192,7 +2192,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2192
2192
|
* The current processor when setting, the value at `key` when getting, or
|
|
2193
2193
|
* the entire dataset when getting without key.
|
|
2194
2194
|
*/
|
|
2195
|
-
data<Key extends keyof Data>(key: Key, value: Data[Key]): Processor<ParseTree, HeadTree, TailTree, CompileTree, CompileResult>;
|
|
2195
|
+
data<Key extends keyof Data$1>(key: Key, value: Data$1[Key]): Processor<ParseTree, HeadTree, TailTree, CompileTree, CompileResult>;
|
|
2196
2196
|
/**
|
|
2197
2197
|
* Freeze a processor.
|
|
2198
2198
|
*
|
|
@@ -2225,7 +2225,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2225
2225
|
* @returns {ParseTree extends undefined ? Node : ParseTree}
|
|
2226
2226
|
* Syntax tree representing `file`.
|
|
2227
2227
|
*/
|
|
2228
|
-
parse(file?: Compatible$
|
|
2228
|
+
parse(file?: Compatible$2 | undefined): ParseTree extends undefined ? Node : ParseTree;
|
|
2229
2229
|
/**
|
|
2230
2230
|
* Process the given file as configured on the processor.
|
|
2231
2231
|
*
|
|
@@ -2268,7 +2268,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2268
2268
|
*
|
|
2269
2269
|
* [rehype-react]: https://github.com/rehypejs/rehype-react
|
|
2270
2270
|
*/
|
|
2271
|
-
process(file: Compatible$
|
|
2271
|
+
process(file: Compatible$2 | undefined, done: ProcessCallback<VFileWithOutput<CompileResult>>): undefined;
|
|
2272
2272
|
/**
|
|
2273
2273
|
* Process the given file as configured on the processor.
|
|
2274
2274
|
*
|
|
@@ -2311,7 +2311,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2311
2311
|
*
|
|
2312
2312
|
* [rehype-react]: https://github.com/rehypejs/rehype-react
|
|
2313
2313
|
*/
|
|
2314
|
-
process(file?: Compatible$
|
|
2314
|
+
process(file?: Compatible$2 | undefined): Promise<VFileWithOutput<CompileResult>>;
|
|
2315
2315
|
/**
|
|
2316
2316
|
* Process the given file as configured on the processor.
|
|
2317
2317
|
*
|
|
@@ -2343,7 +2343,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2343
2343
|
*
|
|
2344
2344
|
* [rehype-react]: https://github.com/rehypejs/rehype-react
|
|
2345
2345
|
*/
|
|
2346
|
-
processSync(file?: Compatible$
|
|
2346
|
+
processSync(file?: Compatible$2 | undefined): VFileWithOutput<CompileResult>;
|
|
2347
2347
|
/**
|
|
2348
2348
|
* Run *transformers* on a syntax tree.
|
|
2349
2349
|
*
|
|
@@ -2421,7 +2421,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2421
2421
|
* Otherwise, a promise rejected with a fatal error or resolved with the
|
|
2422
2422
|
* transformed tree.
|
|
2423
2423
|
*/
|
|
2424
|
-
run(tree: HeadTree extends undefined ? Node : HeadTree, file: Compatible$
|
|
2424
|
+
run(tree: HeadTree extends undefined ? Node : HeadTree, file: Compatible$2 | undefined, done: RunCallback<TailTree extends undefined ? Node : TailTree>): undefined;
|
|
2425
2425
|
/**
|
|
2426
2426
|
* Run *transformers* on a syntax tree.
|
|
2427
2427
|
*
|
|
@@ -2460,7 +2460,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2460
2460
|
* Otherwise, a promise rejected with a fatal error or resolved with the
|
|
2461
2461
|
* transformed tree.
|
|
2462
2462
|
*/
|
|
2463
|
-
run(tree: HeadTree extends undefined ? Node : HeadTree, file?: Compatible$
|
|
2463
|
+
run(tree: HeadTree extends undefined ? Node : HeadTree, file?: Compatible$2 | undefined): Promise<TailTree extends undefined ? Node : TailTree>;
|
|
2464
2464
|
/**
|
|
2465
2465
|
* Run *transformers* on a syntax tree.
|
|
2466
2466
|
*
|
|
@@ -2478,7 +2478,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2478
2478
|
* @returns {TailTree extends undefined ? Node : TailTree}
|
|
2479
2479
|
* Transformed tree.
|
|
2480
2480
|
*/
|
|
2481
|
-
runSync(tree: HeadTree extends undefined ? Node : HeadTree, file?: Compatible$
|
|
2481
|
+
runSync(tree: HeadTree extends undefined ? Node : HeadTree, file?: Compatible$2 | undefined): TailTree extends undefined ? Node : TailTree;
|
|
2482
2482
|
/**
|
|
2483
2483
|
* Compile a syntax tree.
|
|
2484
2484
|
*
|
|
@@ -2508,7 +2508,7 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2508
2508
|
*
|
|
2509
2509
|
* [rehype-react]: https://github.com/rehypejs/rehype-react
|
|
2510
2510
|
*/
|
|
2511
|
-
stringify(tree: CompileTree extends undefined ? Node : CompileTree, file?: Compatible$
|
|
2511
|
+
stringify(tree: CompileTree extends undefined ? Node : CompileTree, file?: Compatible$2 | undefined): CompileResult extends undefined ? Value$1 : CompileResult;
|
|
2512
2512
|
/**
|
|
2513
2513
|
* Configure the processor to use a plugin, a list of usable values, or a
|
|
2514
2514
|
* preset.
|
|
@@ -2686,10 +2686,10 @@ declare class Processor<ParseTree extends unist.Node | undefined = undefined, He
|
|
|
2686
2686
|
}
|
|
2687
2687
|
type Pipeline = Pipeline$1;
|
|
2688
2688
|
type Node = unist.Node;
|
|
2689
|
-
type Compatible$
|
|
2690
|
-
type Value = Value$
|
|
2689
|
+
type Compatible$2 = Compatible$3;
|
|
2690
|
+
type Value$1 = Value$2;
|
|
2691
2691
|
type CompileResultMap = CompileResultMap$1;
|
|
2692
|
-
type Data$
|
|
2692
|
+
type Data$2 = Data$3;
|
|
2693
2693
|
type Settings$1 = Settings$2;
|
|
2694
2694
|
/**
|
|
2695
2695
|
* Acceptable results from compilers.
|
|
@@ -2720,7 +2720,7 @@ type CompileResults = CompileResultMap[keyof CompileResultMap];
|
|
|
2720
2720
|
*
|
|
2721
2721
|
* [rehype-react]: https://github.com/rehypejs/rehype-react
|
|
2722
2722
|
*/
|
|
2723
|
-
type Compiler<Tree extends unist.Node = unist.Node, Result extends CompileResults = CompileResults> = (tree: Tree, file: VFile$
|
|
2723
|
+
type Compiler<Tree extends unist.Node = unist.Node, Result extends CompileResults = CompileResults> = (tree: Tree, file: VFile$2) => Result;
|
|
2724
2724
|
/**
|
|
2725
2725
|
* A **parser** handles the parsing of text to a syntax tree.
|
|
2726
2726
|
*
|
|
@@ -2729,7 +2729,7 @@ type Compiler<Tree extends unist.Node = unist.Node, Result extends CompileResult
|
|
|
2729
2729
|
* It must return the syntax tree representation of the given file
|
|
2730
2730
|
* ({@link Node `Node`}).
|
|
2731
2731
|
*/
|
|
2732
|
-
type Parser<Tree extends unist.Node = unist.Node> = (document: string, file: VFile$
|
|
2732
|
+
type Parser<Tree extends unist.Node = unist.Node> = (document: string, file: VFile$2) => Tree;
|
|
2733
2733
|
/**
|
|
2734
2734
|
* Union of the different ways to add plugins and settings.
|
|
2735
2735
|
*/
|
|
@@ -2784,20 +2784,20 @@ type Preset = {
|
|
|
2784
2784
|
*
|
|
2785
2785
|
* Called with either an error or a result.
|
|
2786
2786
|
*/
|
|
2787
|
-
type ProcessCallback<File extends VFile$
|
|
2787
|
+
type ProcessCallback<File extends VFile$2 = VFile$2> = (error?: Error | undefined, file?: File | undefined) => undefined;
|
|
2788
2788
|
/**
|
|
2789
2789
|
* Callback called when transformers are done.
|
|
2790
2790
|
*
|
|
2791
2791
|
* Called with either an error or results.
|
|
2792
2792
|
*/
|
|
2793
|
-
type RunCallback<Tree extends unist.Node = unist.Node> = (error?: Error | undefined, tree?: Tree | undefined, file?: VFile$
|
|
2793
|
+
type RunCallback<Tree extends unist.Node = unist.Node> = (error?: Error | undefined, tree?: Tree | undefined, file?: VFile$2 | undefined) => undefined;
|
|
2794
2794
|
/**
|
|
2795
2795
|
* Callback passed to transforms.
|
|
2796
2796
|
*
|
|
2797
2797
|
* If the signature of a `transformer` accepts a third argument, the
|
|
2798
2798
|
* transformer may perform asynchronous operations, and must call it.
|
|
2799
2799
|
*/
|
|
2800
|
-
type TransformCallback<Output extends unist.Node = unist.Node> = (error?: Error | undefined, tree?: Output | undefined, file?: VFile$
|
|
2800
|
+
type TransformCallback<Output extends unist.Node = unist.Node> = (error?: Error | undefined, tree?: Output | undefined, file?: VFile$2 | undefined) => undefined;
|
|
2801
2801
|
/**
|
|
2802
2802
|
* Transformers handle syntax trees and files.
|
|
2803
2803
|
*
|
|
@@ -2815,7 +2815,7 @@ type TransformCallback<Output extends unist.Node = unist.Node> = (error?: Error
|
|
|
2815
2815
|
*
|
|
2816
2816
|
* [trough]: https://github.com/wooorm/trough#function-fninput-next
|
|
2817
2817
|
*/
|
|
2818
|
-
type Transformer<Input extends unist.Node = unist.Node, Output extends unist.Node = Input> = (tree: Input, file: VFile$
|
|
2818
|
+
type Transformer<Input extends unist.Node = unist.Node, Output extends unist.Node = Input> = (tree: Input, file: VFile$2, next: TransformCallback<Output>) => (Promise<Output | undefined | void> | Promise<never> | // For some reason this is needed separately.
|
|
2819
2819
|
Output | Error | undefined | void);
|
|
2820
2820
|
/**
|
|
2821
2821
|
* Create a processor based on the input/output of a {@link Plugin plugin}.
|
|
@@ -2827,12 +2827,12 @@ type UsePlugin<ParseTree extends unist.Node | undefined, HeadTree extends unist.
|
|
|
2827
2827
|
* If a result that is not acceptable on a `VFile` is used, that will
|
|
2828
2828
|
* be stored on the `result` field of {@link VFile `VFile`}.
|
|
2829
2829
|
*/
|
|
2830
|
-
type VFileWithOutput<Result extends CompileResults | undefined> = (Result extends Value | undefined ? VFile$
|
|
2830
|
+
type VFileWithOutput<Result extends CompileResults | undefined> = (Result extends Value$1 | undefined ? VFile$2 : VFile$2 & {
|
|
2831
2831
|
result: Result;
|
|
2832
2832
|
});
|
|
2833
2833
|
|
|
2834
2834
|
// See: <https://github.com/sindresorhus/type-fest/blob/main/source/empty-object.d.ts>
|
|
2835
|
-
declare const emptyObjectSymbol: unique symbol
|
|
2835
|
+
declare const emptyObjectSymbol$1: unique symbol
|
|
2836
2836
|
|
|
2837
2837
|
/**
|
|
2838
2838
|
* Interface of known data that can be supported by all plugins.
|
|
@@ -2854,7 +2854,7 @@ declare const emptyObjectSymbol: unique symbol
|
|
|
2854
2854
|
* export {} // You may not need this, but it makes sure the file is a module.
|
|
2855
2855
|
* ```
|
|
2856
2856
|
*/
|
|
2857
|
-
interface Data {
|
|
2857
|
+
interface Data$1 {
|
|
2858
2858
|
settings?: Settings | undefined
|
|
2859
2859
|
}
|
|
2860
2860
|
|
|
@@ -2883,7 +2883,7 @@ interface Data {
|
|
|
2883
2883
|
* ```
|
|
2884
2884
|
*/
|
|
2885
2885
|
interface Settings {
|
|
2886
|
-
[emptyObjectSymbol]?: never
|
|
2886
|
+
[emptyObjectSymbol$1]?: never
|
|
2887
2887
|
}
|
|
2888
2888
|
|
|
2889
2889
|
// Type definitions for source-map 0.7
|
|
@@ -3229,7 +3229,7 @@ type Handlers = Partial<Record<MdastNodes['type'], Handler>>;
|
|
|
3229
3229
|
/**
|
|
3230
3230
|
* Configuration (optional).
|
|
3231
3231
|
*/
|
|
3232
|
-
type Options$
|
|
3232
|
+
type Options$3 = {
|
|
3233
3233
|
/**
|
|
3234
3234
|
* Whether to persist raw HTML in markdown in the hast tree (default:
|
|
3235
3235
|
* `false`).
|
|
@@ -3399,7 +3399,7 @@ type State$1 = {
|
|
|
3399
3399
|
/**
|
|
3400
3400
|
* Configuration.
|
|
3401
3401
|
*/
|
|
3402
|
-
options: Options$
|
|
3402
|
+
options: Options$3;
|
|
3403
3403
|
/**
|
|
3404
3404
|
* Copy a node’s positional info.
|
|
3405
3405
|
*/
|
|
@@ -3474,7 +3474,7 @@ interface Raw$1 extends Literal {
|
|
|
3474
3474
|
/**
|
|
3475
3475
|
* Info associated with hast raw nodes by the ecosystem.
|
|
3476
3476
|
*/
|
|
3477
|
-
interface RawData$1 extends Data$
|
|
3477
|
+
interface RawData$1 extends Data$5 {}
|
|
3478
3478
|
|
|
3479
3479
|
// Register nodes in content.
|
|
3480
3480
|
declare module 'hast' {
|
|
@@ -3543,7 +3543,7 @@ interface Raw extends Literal {
|
|
|
3543
3543
|
/**
|
|
3544
3544
|
* Info associated with hast raw nodes by the ecosystem.
|
|
3545
3545
|
*/
|
|
3546
|
-
interface RawData extends Data$
|
|
3546
|
+
interface RawData extends Data$5 {}
|
|
3547
3547
|
|
|
3548
3548
|
// Register nodes in content.
|
|
3549
3549
|
declare module 'hast' {
|
|
@@ -3594,9 +3594,9 @@ declare module 'mdast' {
|
|
|
3594
3594
|
}
|
|
3595
3595
|
}
|
|
3596
3596
|
|
|
3597
|
-
type Options$
|
|
3597
|
+
type Options$2 = Options$3;
|
|
3598
3598
|
|
|
3599
|
-
type Options = Options$
|
|
3599
|
+
type Options$1 = Options$2;
|
|
3600
3600
|
|
|
3601
3601
|
// Expose node types.
|
|
3602
3602
|
/**
|
|
@@ -3628,7 +3628,7 @@ interface MdxJsxAttributeValueExpression$1 extends Node$2 {
|
|
|
3628
3628
|
* Info associated with mdast MDX JSX attribute value expression nodes by the
|
|
3629
3629
|
* ecosystem.
|
|
3630
3630
|
*/
|
|
3631
|
-
interface MdxJsxAttributeValueExpressionData$1 extends Data$
|
|
3631
|
+
interface MdxJsxAttributeValueExpressionData$1 extends Data$7 {
|
|
3632
3632
|
/**
|
|
3633
3633
|
* Program node from estree.
|
|
3634
3634
|
*/
|
|
@@ -3664,7 +3664,7 @@ interface MdxJsxExpressionAttribute$2 extends Node$2 {
|
|
|
3664
3664
|
* Info associated with mdast MDX JSX expression attribute nodes by the
|
|
3665
3665
|
* ecosystem.
|
|
3666
3666
|
*/
|
|
3667
|
-
interface MdxJsxExpressionAttributeData$1 extends Data$
|
|
3667
|
+
interface MdxJsxExpressionAttributeData$1 extends Data$7 {
|
|
3668
3668
|
/**
|
|
3669
3669
|
* Program node from estree.
|
|
3670
3670
|
*/
|
|
@@ -3702,7 +3702,7 @@ interface MdxJsxAttribute$2 extends Node$2 {
|
|
|
3702
3702
|
* Info associated with mdast MDX JSX attribute nodes by the
|
|
3703
3703
|
* ecosystem.
|
|
3704
3704
|
*/
|
|
3705
|
-
interface MdxJsxAttributeData$1 extends Data$
|
|
3705
|
+
interface MdxJsxAttributeData$1 extends Data$7 {}
|
|
3706
3706
|
|
|
3707
3707
|
/**
|
|
3708
3708
|
* MDX JSX element node, occurring in flow (block).
|
|
@@ -3734,7 +3734,7 @@ interface MdxJsxFlowElement$1 extends Parent {
|
|
|
3734
3734
|
* Info associated with mdast MDX JSX element (flow) nodes by the
|
|
3735
3735
|
* ecosystem.
|
|
3736
3736
|
*/
|
|
3737
|
-
interface MdxJsxFlowElementData$1 extends Data$
|
|
3737
|
+
interface MdxJsxFlowElementData$1 extends Data$6 {}
|
|
3738
3738
|
|
|
3739
3739
|
/**
|
|
3740
3740
|
* MDX JSX element node, occurring in text (phrasing).
|
|
@@ -3766,7 +3766,7 @@ interface MdxJsxTextElement$1 extends Parent {
|
|
|
3766
3766
|
* Info associated with mdast MDX JSX element (text) nodes by the
|
|
3767
3767
|
* ecosystem.
|
|
3768
3768
|
*/
|
|
3769
|
-
interface MdxJsxTextElementData$1 extends Data$
|
|
3769
|
+
interface MdxJsxTextElementData$1 extends Data$6 {}
|
|
3770
3770
|
|
|
3771
3771
|
/**
|
|
3772
3772
|
* MDX JSX element node, occurring in flow (block), for hast.
|
|
@@ -3798,7 +3798,7 @@ interface MdxJsxFlowElementHast$1 extends Parent$1 {
|
|
|
3798
3798
|
* Info associated with hast MDX JSX element (flow) nodes by the
|
|
3799
3799
|
* ecosystem.
|
|
3800
3800
|
*/
|
|
3801
|
-
interface MdxJsxFlowElementHastData$1 extends Data$
|
|
3801
|
+
interface MdxJsxFlowElementHastData$1 extends Data$5 {}
|
|
3802
3802
|
|
|
3803
3803
|
/**
|
|
3804
3804
|
* MDX JSX element node, occurring in text (phrasing), for hast.
|
|
@@ -3830,7 +3830,7 @@ interface MdxJsxTextElementHast$1 extends Parent$1 {
|
|
|
3830
3830
|
* Info associated with hast MDX JSX element (text) nodes by the
|
|
3831
3831
|
* ecosystem.
|
|
3832
3832
|
*/
|
|
3833
|
-
interface MdxJsxTextElementHastData$1 extends Data$
|
|
3833
|
+
interface MdxJsxTextElementHastData$1 extends Data$5 {}
|
|
3834
3834
|
|
|
3835
3835
|
// Add nodes to mdast content.
|
|
3836
3836
|
declare module 'mdast' {
|
|
@@ -4946,7 +4946,7 @@ interface MdxJsxAttributeValueExpression extends Node$2 {
|
|
|
4946
4946
|
* Info associated with mdast MDX JSX attribute value expression nodes by the
|
|
4947
4947
|
* ecosystem.
|
|
4948
4948
|
*/
|
|
4949
|
-
interface MdxJsxAttributeValueExpressionData extends Data$
|
|
4949
|
+
interface MdxJsxAttributeValueExpressionData extends Data$7 {
|
|
4950
4950
|
/**
|
|
4951
4951
|
* Program node from estree.
|
|
4952
4952
|
*/
|
|
@@ -4982,7 +4982,7 @@ interface MdxJsxExpressionAttribute extends Node$2 {
|
|
|
4982
4982
|
* Info associated with mdast MDX JSX expression attribute nodes by the
|
|
4983
4983
|
* ecosystem.
|
|
4984
4984
|
*/
|
|
4985
|
-
interface MdxJsxExpressionAttributeData extends Data$
|
|
4985
|
+
interface MdxJsxExpressionAttributeData extends Data$7 {
|
|
4986
4986
|
/**
|
|
4987
4987
|
* Program node from estree.
|
|
4988
4988
|
*/
|
|
@@ -5020,7 +5020,7 @@ interface MdxJsxAttribute extends Node$2 {
|
|
|
5020
5020
|
* Info associated with mdast MDX JSX attribute nodes by the
|
|
5021
5021
|
* ecosystem.
|
|
5022
5022
|
*/
|
|
5023
|
-
interface MdxJsxAttributeData extends Data$
|
|
5023
|
+
interface MdxJsxAttributeData extends Data$7 {}
|
|
5024
5024
|
|
|
5025
5025
|
/**
|
|
5026
5026
|
* MDX JSX element node, occurring in flow (block).
|
|
@@ -5052,7 +5052,7 @@ interface MdxJsxFlowElement extends Parent {
|
|
|
5052
5052
|
* Info associated with mdast MDX JSX element (flow) nodes by the
|
|
5053
5053
|
* ecosystem.
|
|
5054
5054
|
*/
|
|
5055
|
-
interface MdxJsxFlowElementData extends Data$
|
|
5055
|
+
interface MdxJsxFlowElementData extends Data$6 {}
|
|
5056
5056
|
|
|
5057
5057
|
/**
|
|
5058
5058
|
* MDX JSX element node, occurring in text (phrasing).
|
|
@@ -5084,7 +5084,7 @@ interface MdxJsxTextElement extends Parent {
|
|
|
5084
5084
|
* Info associated with mdast MDX JSX element (text) nodes by the
|
|
5085
5085
|
* ecosystem.
|
|
5086
5086
|
*/
|
|
5087
|
-
interface MdxJsxTextElementData extends Data$
|
|
5087
|
+
interface MdxJsxTextElementData extends Data$6 {}
|
|
5088
5088
|
|
|
5089
5089
|
/**
|
|
5090
5090
|
* MDX JSX element node, occurring in flow (block), for hast.
|
|
@@ -5116,7 +5116,7 @@ interface MdxJsxFlowElementHast extends Parent$1 {
|
|
|
5116
5116
|
* Info associated with hast MDX JSX element (flow) nodes by the
|
|
5117
5117
|
* ecosystem.
|
|
5118
5118
|
*/
|
|
5119
|
-
interface MdxJsxFlowElementHastData extends Data$
|
|
5119
|
+
interface MdxJsxFlowElementHastData extends Data$5 {}
|
|
5120
5120
|
|
|
5121
5121
|
/**
|
|
5122
5122
|
* MDX JSX element node, occurring in text (phrasing), for hast.
|
|
@@ -5148,7 +5148,7 @@ interface MdxJsxTextElementHast extends Parent$1 {
|
|
|
5148
5148
|
* Info associated with hast MDX JSX element (text) nodes by the
|
|
5149
5149
|
* ecosystem.
|
|
5150
5150
|
*/
|
|
5151
|
-
interface MdxJsxTextElementHastData extends Data$
|
|
5151
|
+
interface MdxJsxTextElementHastData extends Data$5 {}
|
|
5152
5152
|
|
|
5153
5153
|
// Add nodes to mdast content.
|
|
5154
5154
|
declare module 'mdast' {
|
|
@@ -5276,7 +5276,7 @@ interface MdxFlowExpression$1 extends Literal$1 {
|
|
|
5276
5276
|
/**
|
|
5277
5277
|
* Info associated with mdast MDX expression (flow) nodes by the ecosystem.
|
|
5278
5278
|
*/
|
|
5279
|
-
interface MdxFlowExpressionData$1 extends Data$
|
|
5279
|
+
interface MdxFlowExpressionData$1 extends Data$6 {
|
|
5280
5280
|
/**
|
|
5281
5281
|
* Program node from estree.
|
|
5282
5282
|
*/
|
|
@@ -5301,7 +5301,7 @@ interface MdxTextExpression$1 extends Literal$1 {
|
|
|
5301
5301
|
/**
|
|
5302
5302
|
* Info associated with mdast MDX expression (text) nodes by the ecosystem.
|
|
5303
5303
|
*/
|
|
5304
|
-
interface MdxTextExpressionData$1 extends Data$
|
|
5304
|
+
interface MdxTextExpressionData$1 extends Data$6 {
|
|
5305
5305
|
/**
|
|
5306
5306
|
* Program node from estree.
|
|
5307
5307
|
*/
|
|
@@ -5326,7 +5326,7 @@ interface MdxFlowExpressionHast$1 extends Literal {
|
|
|
5326
5326
|
/**
|
|
5327
5327
|
* Info associated with hast MDX expression (flow) nodes by the ecosystem.
|
|
5328
5328
|
*/
|
|
5329
|
-
interface MdxFlowExpressionHastData$1 extends Data$
|
|
5329
|
+
interface MdxFlowExpressionHastData$1 extends Data$5 {
|
|
5330
5330
|
/**
|
|
5331
5331
|
* Program node from estree.
|
|
5332
5332
|
*/
|
|
@@ -5351,7 +5351,7 @@ interface MdxTextExpressionHast$1 extends Literal {
|
|
|
5351
5351
|
/**
|
|
5352
5352
|
* Info associated with hast MDX expression (text) nodes by the ecosystem.
|
|
5353
5353
|
*/
|
|
5354
|
-
interface MdxTextExpressionHastData$1 extends Data$
|
|
5354
|
+
interface MdxTextExpressionHastData$1 extends Data$5 {
|
|
5355
5355
|
/**
|
|
5356
5356
|
* Program node from estree.
|
|
5357
5357
|
*/
|
|
@@ -5429,7 +5429,7 @@ interface MdxFlowExpression extends Literal$1 {
|
|
|
5429
5429
|
/**
|
|
5430
5430
|
* Info associated with mdast MDX expression (flow) nodes by the ecosystem.
|
|
5431
5431
|
*/
|
|
5432
|
-
interface MdxFlowExpressionData extends Data$
|
|
5432
|
+
interface MdxFlowExpressionData extends Data$6 {
|
|
5433
5433
|
/**
|
|
5434
5434
|
* Program node from estree.
|
|
5435
5435
|
*/
|
|
@@ -5454,7 +5454,7 @@ interface MdxTextExpression extends Literal$1 {
|
|
|
5454
5454
|
/**
|
|
5455
5455
|
* Info associated with mdast MDX expression (text) nodes by the ecosystem.
|
|
5456
5456
|
*/
|
|
5457
|
-
interface MdxTextExpressionData extends Data$
|
|
5457
|
+
interface MdxTextExpressionData extends Data$6 {
|
|
5458
5458
|
/**
|
|
5459
5459
|
* Program node from estree.
|
|
5460
5460
|
*/
|
|
@@ -5479,7 +5479,7 @@ interface MdxFlowExpressionHast extends Literal {
|
|
|
5479
5479
|
/**
|
|
5480
5480
|
* Info associated with hast MDX expression (flow) nodes by the ecosystem.
|
|
5481
5481
|
*/
|
|
5482
|
-
interface MdxFlowExpressionHastData extends Data$
|
|
5482
|
+
interface MdxFlowExpressionHastData extends Data$5 {
|
|
5483
5483
|
/**
|
|
5484
5484
|
* Program node from estree.
|
|
5485
5485
|
*/
|
|
@@ -5504,7 +5504,7 @@ interface MdxTextExpressionHast extends Literal {
|
|
|
5504
5504
|
/**
|
|
5505
5505
|
* Info associated with hast MDX expression (text) nodes by the ecosystem.
|
|
5506
5506
|
*/
|
|
5507
|
-
interface MdxTextExpressionHastData extends Data$
|
|
5507
|
+
interface MdxTextExpressionHastData extends Data$5 {
|
|
5508
5508
|
/**
|
|
5509
5509
|
* Program node from estree.
|
|
5510
5510
|
*/
|
|
@@ -5582,7 +5582,7 @@ interface MdxjsEsm$1 extends Literal$1 {
|
|
|
5582
5582
|
/**
|
|
5583
5583
|
* Info associated with mdast MDX.js ESM nodes by the ecosystem.
|
|
5584
5584
|
*/
|
|
5585
|
-
interface MdxjsEsmData$1 extends Data$
|
|
5585
|
+
interface MdxjsEsmData$1 extends Data$6 {
|
|
5586
5586
|
/**
|
|
5587
5587
|
* Program node from estree.
|
|
5588
5588
|
*/
|
|
@@ -5607,7 +5607,7 @@ interface MdxjsEsmHast$1 extends Literal {
|
|
|
5607
5607
|
/**
|
|
5608
5608
|
* Info associated with hast MDX.js ESM nodes by the ecosystem.
|
|
5609
5609
|
*/
|
|
5610
|
-
interface MdxjsEsmHastData$1 extends Data$
|
|
5610
|
+
interface MdxjsEsmHastData$1 extends Data$5 {
|
|
5611
5611
|
/**
|
|
5612
5612
|
* Program node from estree.
|
|
5613
5613
|
*/
|
|
@@ -5659,7 +5659,7 @@ interface MdxjsEsm extends Literal$1 {
|
|
|
5659
5659
|
/**
|
|
5660
5660
|
* Info associated with mdast MDX.js ESM nodes by the ecosystem.
|
|
5661
5661
|
*/
|
|
5662
|
-
interface MdxjsEsmData extends Data$
|
|
5662
|
+
interface MdxjsEsmData extends Data$6 {
|
|
5663
5663
|
/**
|
|
5664
5664
|
* Program node from estree.
|
|
5665
5665
|
*/
|
|
@@ -5684,7 +5684,7 @@ interface MdxjsEsmHast extends Literal {
|
|
|
5684
5684
|
/**
|
|
5685
5685
|
* Info associated with hast MDX.js ESM nodes by the ecosystem.
|
|
5686
5686
|
*/
|
|
5687
|
-
interface MdxjsEsmHastData extends Data$
|
|
5687
|
+
interface MdxjsEsmHastData extends Data$5 {
|
|
5688
5688
|
/**
|
|
5689
5689
|
* Program node from estree.
|
|
5690
5690
|
*/
|
|
@@ -5723,7 +5723,7 @@ type StylePropertyNameCase$1 = StylePropertyNameCase$2;
|
|
|
5723
5723
|
|
|
5724
5724
|
type ElementAttributeNameCase = ElementAttributeNameCase$1;
|
|
5725
5725
|
type StylePropertyNameCase = StylePropertyNameCase$1;
|
|
5726
|
-
type RemarkRehypeOptions = Options;
|
|
5726
|
+
type RemarkRehypeOptions = Options$1;
|
|
5727
5727
|
type SourceMapGenerator = typeof SourceMapGenerator$1;
|
|
5728
5728
|
/**
|
|
5729
5729
|
* Configuration for `createProcessor`.
|
|
@@ -5884,6 +5884,1585 @@ type ProcessorOptions$1 = {
|
|
|
5884
5884
|
tableCellAlignToStyle?: boolean | null | undefined;
|
|
5885
5885
|
};
|
|
5886
5886
|
|
|
5887
|
+
declare class VFile$1 {
|
|
5888
|
+
/**
|
|
5889
|
+
* Create a new virtual file.
|
|
5890
|
+
*
|
|
5891
|
+
* `options` is treated as:
|
|
5892
|
+
*
|
|
5893
|
+
* * `string` or `Uint8Array` — `{value: options}`
|
|
5894
|
+
* * `URL` — `{path: options}`
|
|
5895
|
+
* * `VFile` — shallow copies its data over to the new file
|
|
5896
|
+
* * `object` — all fields are shallow copied over to the new file
|
|
5897
|
+
*
|
|
5898
|
+
* Path related fields are set in the following order (least specific to
|
|
5899
|
+
* most specific): `history`, `path`, `basename`, `stem`, `extname`,
|
|
5900
|
+
* `dirname`.
|
|
5901
|
+
*
|
|
5902
|
+
* You cannot set `dirname` or `extname` without setting either `history`,
|
|
5903
|
+
* `path`, `basename`, or `stem` too.
|
|
5904
|
+
*
|
|
5905
|
+
* @param {Compatible | null | undefined} [value]
|
|
5906
|
+
* File value.
|
|
5907
|
+
* @returns
|
|
5908
|
+
* New instance.
|
|
5909
|
+
*/
|
|
5910
|
+
constructor(value?: Compatible$1 | null | undefined);
|
|
5911
|
+
/**
|
|
5912
|
+
* Base of `path` (default: `process.cwd()` or `'/'` in browsers).
|
|
5913
|
+
*
|
|
5914
|
+
* @type {string}
|
|
5915
|
+
*/
|
|
5916
|
+
cwd: string;
|
|
5917
|
+
/**
|
|
5918
|
+
* Place to store custom info (default: `{}`).
|
|
5919
|
+
*
|
|
5920
|
+
* It’s OK to store custom data directly on the file but moving it to
|
|
5921
|
+
* `data` is recommended.
|
|
5922
|
+
*
|
|
5923
|
+
* @type {Data}
|
|
5924
|
+
*/
|
|
5925
|
+
data: Data;
|
|
5926
|
+
/**
|
|
5927
|
+
* List of file paths the file moved between.
|
|
5928
|
+
*
|
|
5929
|
+
* The first is the original path and the last is the current path.
|
|
5930
|
+
*
|
|
5931
|
+
* @type {Array<string>}
|
|
5932
|
+
*/
|
|
5933
|
+
history: Array<string>;
|
|
5934
|
+
/**
|
|
5935
|
+
* List of messages associated with the file.
|
|
5936
|
+
*
|
|
5937
|
+
* @type {Array<VFileMessage>}
|
|
5938
|
+
*/
|
|
5939
|
+
messages: Array<VFileMessage>;
|
|
5940
|
+
/**
|
|
5941
|
+
* Raw value.
|
|
5942
|
+
*
|
|
5943
|
+
* @type {Value}
|
|
5944
|
+
*/
|
|
5945
|
+
value: Value;
|
|
5946
|
+
/**
|
|
5947
|
+
* Source map.
|
|
5948
|
+
*
|
|
5949
|
+
* This type is equivalent to the `RawSourceMap` type from the `source-map`
|
|
5950
|
+
* module.
|
|
5951
|
+
*
|
|
5952
|
+
* @type {Map | null | undefined}
|
|
5953
|
+
*/
|
|
5954
|
+
map: Map$1 | null | undefined;
|
|
5955
|
+
/**
|
|
5956
|
+
* Custom, non-string, compiled, representation.
|
|
5957
|
+
*
|
|
5958
|
+
* This is used by unified to store non-string results.
|
|
5959
|
+
* One example is when turning markdown into React nodes.
|
|
5960
|
+
*
|
|
5961
|
+
* @type {unknown}
|
|
5962
|
+
*/
|
|
5963
|
+
result: unknown;
|
|
5964
|
+
/**
|
|
5965
|
+
* Whether a file was saved to disk.
|
|
5966
|
+
*
|
|
5967
|
+
* This is used by vfile reporters.
|
|
5968
|
+
*
|
|
5969
|
+
* @type {boolean}
|
|
5970
|
+
*/
|
|
5971
|
+
stored: boolean;
|
|
5972
|
+
/**
|
|
5973
|
+
* Set basename (including extname) (`'index.min.js'`).
|
|
5974
|
+
*
|
|
5975
|
+
* Cannot contain path separators (`'/'` on unix, macOS, and browsers, `'\'`
|
|
5976
|
+
* on windows).
|
|
5977
|
+
* Cannot be nullified (use `file.path = file.dirname` instead).
|
|
5978
|
+
*
|
|
5979
|
+
* @param {string} basename
|
|
5980
|
+
* Basename.
|
|
5981
|
+
* @returns {undefined}
|
|
5982
|
+
* Nothing.
|
|
5983
|
+
*/
|
|
5984
|
+
set basename(basename: string);
|
|
5985
|
+
/**
|
|
5986
|
+
* Get the basename (including extname) (example: `'index.min.js'`).
|
|
5987
|
+
*
|
|
5988
|
+
* @returns {string | undefined}
|
|
5989
|
+
* Basename.
|
|
5990
|
+
*/
|
|
5991
|
+
get basename(): string | undefined;
|
|
5992
|
+
/**
|
|
5993
|
+
* Set the full path (example: `'~/index.min.js'`).
|
|
5994
|
+
*
|
|
5995
|
+
* Cannot be nullified.
|
|
5996
|
+
* You can set a file URL (a `URL` object with a `file:` protocol) which will
|
|
5997
|
+
* be turned into a path with `url.fileURLToPath`.
|
|
5998
|
+
*
|
|
5999
|
+
* @param {URL | string} path
|
|
6000
|
+
* Path.
|
|
6001
|
+
* @returns {undefined}
|
|
6002
|
+
* Nothing.
|
|
6003
|
+
*/
|
|
6004
|
+
set path(path: string | URL);
|
|
6005
|
+
/**
|
|
6006
|
+
* Get the full path (example: `'~/index.min.js'`).
|
|
6007
|
+
*
|
|
6008
|
+
* @returns {string}
|
|
6009
|
+
* Path.
|
|
6010
|
+
*/
|
|
6011
|
+
get path(): string;
|
|
6012
|
+
/**
|
|
6013
|
+
* Set the parent path (example: `'~'`).
|
|
6014
|
+
*
|
|
6015
|
+
* Cannot be set if there’s no `path` yet.
|
|
6016
|
+
*
|
|
6017
|
+
* @param {string | undefined} dirname
|
|
6018
|
+
* Dirname.
|
|
6019
|
+
* @returns {undefined}
|
|
6020
|
+
* Nothing.
|
|
6021
|
+
*/
|
|
6022
|
+
set dirname(dirname: string | undefined);
|
|
6023
|
+
/**
|
|
6024
|
+
* Get the parent path (example: `'~'`).
|
|
6025
|
+
*
|
|
6026
|
+
* @returns {string | undefined}
|
|
6027
|
+
* Dirname.
|
|
6028
|
+
*/
|
|
6029
|
+
get dirname(): string | undefined;
|
|
6030
|
+
/**
|
|
6031
|
+
* Set the extname (including dot) (example: `'.js'`).
|
|
6032
|
+
*
|
|
6033
|
+
* Cannot contain path separators (`'/'` on unix, macOS, and browsers, `'\'`
|
|
6034
|
+
* on windows).
|
|
6035
|
+
* Cannot be set if there’s no `path` yet.
|
|
6036
|
+
*
|
|
6037
|
+
* @param {string | undefined} extname
|
|
6038
|
+
* Extname.
|
|
6039
|
+
* @returns {undefined}
|
|
6040
|
+
* Nothing.
|
|
6041
|
+
*/
|
|
6042
|
+
set extname(extname: string | undefined);
|
|
6043
|
+
/**
|
|
6044
|
+
* Get the extname (including dot) (example: `'.js'`).
|
|
6045
|
+
*
|
|
6046
|
+
* @returns {string | undefined}
|
|
6047
|
+
* Extname.
|
|
6048
|
+
*/
|
|
6049
|
+
get extname(): string | undefined;
|
|
6050
|
+
/**
|
|
6051
|
+
* Set the stem (basename w/o extname) (example: `'index.min'`).
|
|
6052
|
+
*
|
|
6053
|
+
* Cannot contain path separators (`'/'` on unix, macOS, and browsers, `'\'`
|
|
6054
|
+
* on windows).
|
|
6055
|
+
* Cannot be nullified (use `file.path = file.dirname` instead).
|
|
6056
|
+
*
|
|
6057
|
+
* @param {string} stem
|
|
6058
|
+
* Stem.
|
|
6059
|
+
* @returns {undefined}
|
|
6060
|
+
* Nothing.
|
|
6061
|
+
*/
|
|
6062
|
+
set stem(stem: string);
|
|
6063
|
+
/**
|
|
6064
|
+
* Get the stem (basename w/o extname) (example: `'index.min'`).
|
|
6065
|
+
*
|
|
6066
|
+
* @returns {string | undefined}
|
|
6067
|
+
* Stem.
|
|
6068
|
+
*/
|
|
6069
|
+
get stem(): string | undefined;
|
|
6070
|
+
/**
|
|
6071
|
+
* Create a fatal message for `reason` associated with the file.
|
|
6072
|
+
*
|
|
6073
|
+
* The `fatal` field of the message is set to `true` (error; file not usable)
|
|
6074
|
+
* and the `file` field is set to the current file path.
|
|
6075
|
+
* The message is added to the `messages` field on `file`.
|
|
6076
|
+
*
|
|
6077
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6078
|
+
*
|
|
6079
|
+
* @overload
|
|
6080
|
+
* @param {string} reason
|
|
6081
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6082
|
+
* @returns {never}
|
|
6083
|
+
*
|
|
6084
|
+
* @overload
|
|
6085
|
+
* @param {string} reason
|
|
6086
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6087
|
+
* @param {string | null | undefined} [origin]
|
|
6088
|
+
* @returns {never}
|
|
6089
|
+
*
|
|
6090
|
+
* @overload
|
|
6091
|
+
* @param {string} reason
|
|
6092
|
+
* @param {Point | Position | null | undefined} place
|
|
6093
|
+
* @param {string | null | undefined} [origin]
|
|
6094
|
+
* @returns {never}
|
|
6095
|
+
*
|
|
6096
|
+
* @overload
|
|
6097
|
+
* @param {string} reason
|
|
6098
|
+
* @param {string | null | undefined} [origin]
|
|
6099
|
+
* @returns {never}
|
|
6100
|
+
*
|
|
6101
|
+
* @overload
|
|
6102
|
+
* @param {Error | VFileMessage} cause
|
|
6103
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6104
|
+
* @param {string | null | undefined} [origin]
|
|
6105
|
+
* @returns {never}
|
|
6106
|
+
*
|
|
6107
|
+
* @overload
|
|
6108
|
+
* @param {Error | VFileMessage} cause
|
|
6109
|
+
* @param {Point | Position | null | undefined} place
|
|
6110
|
+
* @param {string | null | undefined} [origin]
|
|
6111
|
+
* @returns {never}
|
|
6112
|
+
*
|
|
6113
|
+
* @overload
|
|
6114
|
+
* @param {Error | VFileMessage} cause
|
|
6115
|
+
* @param {string | null | undefined} [origin]
|
|
6116
|
+
* @returns {never}
|
|
6117
|
+
*
|
|
6118
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6119
|
+
* Reason for message, should use markdown.
|
|
6120
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6121
|
+
* Configuration (optional).
|
|
6122
|
+
* @param {string | null | undefined} [origin]
|
|
6123
|
+
* Place in code where the message originates (example:
|
|
6124
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6125
|
+
* @returns {never}
|
|
6126
|
+
* Never.
|
|
6127
|
+
* @throws {VFileMessage}
|
|
6128
|
+
* Message.
|
|
6129
|
+
*/
|
|
6130
|
+
fail(reason: string, options?: Options$5 | null | undefined): never;
|
|
6131
|
+
/**
|
|
6132
|
+
* Create a fatal message for `reason` associated with the file.
|
|
6133
|
+
*
|
|
6134
|
+
* The `fatal` field of the message is set to `true` (error; file not usable)
|
|
6135
|
+
* and the `file` field is set to the current file path.
|
|
6136
|
+
* The message is added to the `messages` field on `file`.
|
|
6137
|
+
*
|
|
6138
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6139
|
+
*
|
|
6140
|
+
* @overload
|
|
6141
|
+
* @param {string} reason
|
|
6142
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6143
|
+
* @returns {never}
|
|
6144
|
+
*
|
|
6145
|
+
* @overload
|
|
6146
|
+
* @param {string} reason
|
|
6147
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6148
|
+
* @param {string | null | undefined} [origin]
|
|
6149
|
+
* @returns {never}
|
|
6150
|
+
*
|
|
6151
|
+
* @overload
|
|
6152
|
+
* @param {string} reason
|
|
6153
|
+
* @param {Point | Position | null | undefined} place
|
|
6154
|
+
* @param {string | null | undefined} [origin]
|
|
6155
|
+
* @returns {never}
|
|
6156
|
+
*
|
|
6157
|
+
* @overload
|
|
6158
|
+
* @param {string} reason
|
|
6159
|
+
* @param {string | null | undefined} [origin]
|
|
6160
|
+
* @returns {never}
|
|
6161
|
+
*
|
|
6162
|
+
* @overload
|
|
6163
|
+
* @param {Error | VFileMessage} cause
|
|
6164
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6165
|
+
* @param {string | null | undefined} [origin]
|
|
6166
|
+
* @returns {never}
|
|
6167
|
+
*
|
|
6168
|
+
* @overload
|
|
6169
|
+
* @param {Error | VFileMessage} cause
|
|
6170
|
+
* @param {Point | Position | null | undefined} place
|
|
6171
|
+
* @param {string | null | undefined} [origin]
|
|
6172
|
+
* @returns {never}
|
|
6173
|
+
*
|
|
6174
|
+
* @overload
|
|
6175
|
+
* @param {Error | VFileMessage} cause
|
|
6176
|
+
* @param {string | null | undefined} [origin]
|
|
6177
|
+
* @returns {never}
|
|
6178
|
+
*
|
|
6179
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6180
|
+
* Reason for message, should use markdown.
|
|
6181
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6182
|
+
* Configuration (optional).
|
|
6183
|
+
* @param {string | null | undefined} [origin]
|
|
6184
|
+
* Place in code where the message originates (example:
|
|
6185
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6186
|
+
* @returns {never}
|
|
6187
|
+
* Never.
|
|
6188
|
+
* @throws {VFileMessage}
|
|
6189
|
+
* Message.
|
|
6190
|
+
*/
|
|
6191
|
+
fail(reason: string, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): never;
|
|
6192
|
+
/**
|
|
6193
|
+
* Create a fatal message for `reason` associated with the file.
|
|
6194
|
+
*
|
|
6195
|
+
* The `fatal` field of the message is set to `true` (error; file not usable)
|
|
6196
|
+
* and the `file` field is set to the current file path.
|
|
6197
|
+
* The message is added to the `messages` field on `file`.
|
|
6198
|
+
*
|
|
6199
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6200
|
+
*
|
|
6201
|
+
* @overload
|
|
6202
|
+
* @param {string} reason
|
|
6203
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6204
|
+
* @returns {never}
|
|
6205
|
+
*
|
|
6206
|
+
* @overload
|
|
6207
|
+
* @param {string} reason
|
|
6208
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6209
|
+
* @param {string | null | undefined} [origin]
|
|
6210
|
+
* @returns {never}
|
|
6211
|
+
*
|
|
6212
|
+
* @overload
|
|
6213
|
+
* @param {string} reason
|
|
6214
|
+
* @param {Point | Position | null | undefined} place
|
|
6215
|
+
* @param {string | null | undefined} [origin]
|
|
6216
|
+
* @returns {never}
|
|
6217
|
+
*
|
|
6218
|
+
* @overload
|
|
6219
|
+
* @param {string} reason
|
|
6220
|
+
* @param {string | null | undefined} [origin]
|
|
6221
|
+
* @returns {never}
|
|
6222
|
+
*
|
|
6223
|
+
* @overload
|
|
6224
|
+
* @param {Error | VFileMessage} cause
|
|
6225
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6226
|
+
* @param {string | null | undefined} [origin]
|
|
6227
|
+
* @returns {never}
|
|
6228
|
+
*
|
|
6229
|
+
* @overload
|
|
6230
|
+
* @param {Error | VFileMessage} cause
|
|
6231
|
+
* @param {Point | Position | null | undefined} place
|
|
6232
|
+
* @param {string | null | undefined} [origin]
|
|
6233
|
+
* @returns {never}
|
|
6234
|
+
*
|
|
6235
|
+
* @overload
|
|
6236
|
+
* @param {Error | VFileMessage} cause
|
|
6237
|
+
* @param {string | null | undefined} [origin]
|
|
6238
|
+
* @returns {never}
|
|
6239
|
+
*
|
|
6240
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6241
|
+
* Reason for message, should use markdown.
|
|
6242
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6243
|
+
* Configuration (optional).
|
|
6244
|
+
* @param {string | null | undefined} [origin]
|
|
6245
|
+
* Place in code where the message originates (example:
|
|
6246
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6247
|
+
* @returns {never}
|
|
6248
|
+
* Never.
|
|
6249
|
+
* @throws {VFileMessage}
|
|
6250
|
+
* Message.
|
|
6251
|
+
*/
|
|
6252
|
+
fail(reason: string, place: Point$2 | Position$2 | null | undefined, origin?: string | null | undefined): never;
|
|
6253
|
+
/**
|
|
6254
|
+
* Create a fatal message for `reason` associated with the file.
|
|
6255
|
+
*
|
|
6256
|
+
* The `fatal` field of the message is set to `true` (error; file not usable)
|
|
6257
|
+
* and the `file` field is set to the current file path.
|
|
6258
|
+
* The message is added to the `messages` field on `file`.
|
|
6259
|
+
*
|
|
6260
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6261
|
+
*
|
|
6262
|
+
* @overload
|
|
6263
|
+
* @param {string} reason
|
|
6264
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6265
|
+
* @returns {never}
|
|
6266
|
+
*
|
|
6267
|
+
* @overload
|
|
6268
|
+
* @param {string} reason
|
|
6269
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6270
|
+
* @param {string | null | undefined} [origin]
|
|
6271
|
+
* @returns {never}
|
|
6272
|
+
*
|
|
6273
|
+
* @overload
|
|
6274
|
+
* @param {string} reason
|
|
6275
|
+
* @param {Point | Position | null | undefined} place
|
|
6276
|
+
* @param {string | null | undefined} [origin]
|
|
6277
|
+
* @returns {never}
|
|
6278
|
+
*
|
|
6279
|
+
* @overload
|
|
6280
|
+
* @param {string} reason
|
|
6281
|
+
* @param {string | null | undefined} [origin]
|
|
6282
|
+
* @returns {never}
|
|
6283
|
+
*
|
|
6284
|
+
* @overload
|
|
6285
|
+
* @param {Error | VFileMessage} cause
|
|
6286
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6287
|
+
* @param {string | null | undefined} [origin]
|
|
6288
|
+
* @returns {never}
|
|
6289
|
+
*
|
|
6290
|
+
* @overload
|
|
6291
|
+
* @param {Error | VFileMessage} cause
|
|
6292
|
+
* @param {Point | Position | null | undefined} place
|
|
6293
|
+
* @param {string | null | undefined} [origin]
|
|
6294
|
+
* @returns {never}
|
|
6295
|
+
*
|
|
6296
|
+
* @overload
|
|
6297
|
+
* @param {Error | VFileMessage} cause
|
|
6298
|
+
* @param {string | null | undefined} [origin]
|
|
6299
|
+
* @returns {never}
|
|
6300
|
+
*
|
|
6301
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6302
|
+
* Reason for message, should use markdown.
|
|
6303
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6304
|
+
* Configuration (optional).
|
|
6305
|
+
* @param {string | null | undefined} [origin]
|
|
6306
|
+
* Place in code where the message originates (example:
|
|
6307
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6308
|
+
* @returns {never}
|
|
6309
|
+
* Never.
|
|
6310
|
+
* @throws {VFileMessage}
|
|
6311
|
+
* Message.
|
|
6312
|
+
*/
|
|
6313
|
+
fail(reason: string, origin?: string | null | undefined): never;
|
|
6314
|
+
/**
|
|
6315
|
+
* Create a fatal message for `reason` associated with the file.
|
|
6316
|
+
*
|
|
6317
|
+
* The `fatal` field of the message is set to `true` (error; file not usable)
|
|
6318
|
+
* and the `file` field is set to the current file path.
|
|
6319
|
+
* The message is added to the `messages` field on `file`.
|
|
6320
|
+
*
|
|
6321
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6322
|
+
*
|
|
6323
|
+
* @overload
|
|
6324
|
+
* @param {string} reason
|
|
6325
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6326
|
+
* @returns {never}
|
|
6327
|
+
*
|
|
6328
|
+
* @overload
|
|
6329
|
+
* @param {string} reason
|
|
6330
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6331
|
+
* @param {string | null | undefined} [origin]
|
|
6332
|
+
* @returns {never}
|
|
6333
|
+
*
|
|
6334
|
+
* @overload
|
|
6335
|
+
* @param {string} reason
|
|
6336
|
+
* @param {Point | Position | null | undefined} place
|
|
6337
|
+
* @param {string | null | undefined} [origin]
|
|
6338
|
+
* @returns {never}
|
|
6339
|
+
*
|
|
6340
|
+
* @overload
|
|
6341
|
+
* @param {string} reason
|
|
6342
|
+
* @param {string | null | undefined} [origin]
|
|
6343
|
+
* @returns {never}
|
|
6344
|
+
*
|
|
6345
|
+
* @overload
|
|
6346
|
+
* @param {Error | VFileMessage} cause
|
|
6347
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6348
|
+
* @param {string | null | undefined} [origin]
|
|
6349
|
+
* @returns {never}
|
|
6350
|
+
*
|
|
6351
|
+
* @overload
|
|
6352
|
+
* @param {Error | VFileMessage} cause
|
|
6353
|
+
* @param {Point | Position | null | undefined} place
|
|
6354
|
+
* @param {string | null | undefined} [origin]
|
|
6355
|
+
* @returns {never}
|
|
6356
|
+
*
|
|
6357
|
+
* @overload
|
|
6358
|
+
* @param {Error | VFileMessage} cause
|
|
6359
|
+
* @param {string | null | undefined} [origin]
|
|
6360
|
+
* @returns {never}
|
|
6361
|
+
*
|
|
6362
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6363
|
+
* Reason for message, should use markdown.
|
|
6364
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6365
|
+
* Configuration (optional).
|
|
6366
|
+
* @param {string | null | undefined} [origin]
|
|
6367
|
+
* Place in code where the message originates (example:
|
|
6368
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6369
|
+
* @returns {never}
|
|
6370
|
+
* Never.
|
|
6371
|
+
* @throws {VFileMessage}
|
|
6372
|
+
* Message.
|
|
6373
|
+
*/
|
|
6374
|
+
fail(cause: Error | VFileMessage, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): never;
|
|
6375
|
+
/**
|
|
6376
|
+
* Create a fatal message for `reason` associated with the file.
|
|
6377
|
+
*
|
|
6378
|
+
* The `fatal` field of the message is set to `true` (error; file not usable)
|
|
6379
|
+
* and the `file` field is set to the current file path.
|
|
6380
|
+
* The message is added to the `messages` field on `file`.
|
|
6381
|
+
*
|
|
6382
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6383
|
+
*
|
|
6384
|
+
* @overload
|
|
6385
|
+
* @param {string} reason
|
|
6386
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6387
|
+
* @returns {never}
|
|
6388
|
+
*
|
|
6389
|
+
* @overload
|
|
6390
|
+
* @param {string} reason
|
|
6391
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6392
|
+
* @param {string | null | undefined} [origin]
|
|
6393
|
+
* @returns {never}
|
|
6394
|
+
*
|
|
6395
|
+
* @overload
|
|
6396
|
+
* @param {string} reason
|
|
6397
|
+
* @param {Point | Position | null | undefined} place
|
|
6398
|
+
* @param {string | null | undefined} [origin]
|
|
6399
|
+
* @returns {never}
|
|
6400
|
+
*
|
|
6401
|
+
* @overload
|
|
6402
|
+
* @param {string} reason
|
|
6403
|
+
* @param {string | null | undefined} [origin]
|
|
6404
|
+
* @returns {never}
|
|
6405
|
+
*
|
|
6406
|
+
* @overload
|
|
6407
|
+
* @param {Error | VFileMessage} cause
|
|
6408
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6409
|
+
* @param {string | null | undefined} [origin]
|
|
6410
|
+
* @returns {never}
|
|
6411
|
+
*
|
|
6412
|
+
* @overload
|
|
6413
|
+
* @param {Error | VFileMessage} cause
|
|
6414
|
+
* @param {Point | Position | null | undefined} place
|
|
6415
|
+
* @param {string | null | undefined} [origin]
|
|
6416
|
+
* @returns {never}
|
|
6417
|
+
*
|
|
6418
|
+
* @overload
|
|
6419
|
+
* @param {Error | VFileMessage} cause
|
|
6420
|
+
* @param {string | null | undefined} [origin]
|
|
6421
|
+
* @returns {never}
|
|
6422
|
+
*
|
|
6423
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6424
|
+
* Reason for message, should use markdown.
|
|
6425
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6426
|
+
* Configuration (optional).
|
|
6427
|
+
* @param {string | null | undefined} [origin]
|
|
6428
|
+
* Place in code where the message originates (example:
|
|
6429
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6430
|
+
* @returns {never}
|
|
6431
|
+
* Never.
|
|
6432
|
+
* @throws {VFileMessage}
|
|
6433
|
+
* Message.
|
|
6434
|
+
*/
|
|
6435
|
+
fail(cause: Error | VFileMessage, place: Point$2 | Position$2 | null | undefined, origin?: string | null | undefined): never;
|
|
6436
|
+
/**
|
|
6437
|
+
* Create a fatal message for `reason` associated with the file.
|
|
6438
|
+
*
|
|
6439
|
+
* The `fatal` field of the message is set to `true` (error; file not usable)
|
|
6440
|
+
* and the `file` field is set to the current file path.
|
|
6441
|
+
* The message is added to the `messages` field on `file`.
|
|
6442
|
+
*
|
|
6443
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6444
|
+
*
|
|
6445
|
+
* @overload
|
|
6446
|
+
* @param {string} reason
|
|
6447
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6448
|
+
* @returns {never}
|
|
6449
|
+
*
|
|
6450
|
+
* @overload
|
|
6451
|
+
* @param {string} reason
|
|
6452
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6453
|
+
* @param {string | null | undefined} [origin]
|
|
6454
|
+
* @returns {never}
|
|
6455
|
+
*
|
|
6456
|
+
* @overload
|
|
6457
|
+
* @param {string} reason
|
|
6458
|
+
* @param {Point | Position | null | undefined} place
|
|
6459
|
+
* @param {string | null | undefined} [origin]
|
|
6460
|
+
* @returns {never}
|
|
6461
|
+
*
|
|
6462
|
+
* @overload
|
|
6463
|
+
* @param {string} reason
|
|
6464
|
+
* @param {string | null | undefined} [origin]
|
|
6465
|
+
* @returns {never}
|
|
6466
|
+
*
|
|
6467
|
+
* @overload
|
|
6468
|
+
* @param {Error | VFileMessage} cause
|
|
6469
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6470
|
+
* @param {string | null | undefined} [origin]
|
|
6471
|
+
* @returns {never}
|
|
6472
|
+
*
|
|
6473
|
+
* @overload
|
|
6474
|
+
* @param {Error | VFileMessage} cause
|
|
6475
|
+
* @param {Point | Position | null | undefined} place
|
|
6476
|
+
* @param {string | null | undefined} [origin]
|
|
6477
|
+
* @returns {never}
|
|
6478
|
+
*
|
|
6479
|
+
* @overload
|
|
6480
|
+
* @param {Error | VFileMessage} cause
|
|
6481
|
+
* @param {string | null | undefined} [origin]
|
|
6482
|
+
* @returns {never}
|
|
6483
|
+
*
|
|
6484
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6485
|
+
* Reason for message, should use markdown.
|
|
6486
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6487
|
+
* Configuration (optional).
|
|
6488
|
+
* @param {string | null | undefined} [origin]
|
|
6489
|
+
* Place in code where the message originates (example:
|
|
6490
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6491
|
+
* @returns {never}
|
|
6492
|
+
* Never.
|
|
6493
|
+
* @throws {VFileMessage}
|
|
6494
|
+
* Message.
|
|
6495
|
+
*/
|
|
6496
|
+
fail(cause: Error | VFileMessage, origin?: string | null | undefined): never;
|
|
6497
|
+
/**
|
|
6498
|
+
* Create an info message for `reason` associated with the file.
|
|
6499
|
+
*
|
|
6500
|
+
* The `fatal` field of the message is set to `undefined` (info; change
|
|
6501
|
+
* likely not needed) and the `file` field is set to the current file path.
|
|
6502
|
+
* The message is added to the `messages` field on `file`.
|
|
6503
|
+
*
|
|
6504
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6505
|
+
*
|
|
6506
|
+
* @overload
|
|
6507
|
+
* @param {string} reason
|
|
6508
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6509
|
+
* @returns {VFileMessage}
|
|
6510
|
+
*
|
|
6511
|
+
* @overload
|
|
6512
|
+
* @param {string} reason
|
|
6513
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6514
|
+
* @param {string | null | undefined} [origin]
|
|
6515
|
+
* @returns {VFileMessage}
|
|
6516
|
+
*
|
|
6517
|
+
* @overload
|
|
6518
|
+
* @param {string} reason
|
|
6519
|
+
* @param {Point | Position | null | undefined} place
|
|
6520
|
+
* @param {string | null | undefined} [origin]
|
|
6521
|
+
* @returns {VFileMessage}
|
|
6522
|
+
*
|
|
6523
|
+
* @overload
|
|
6524
|
+
* @param {string} reason
|
|
6525
|
+
* @param {string | null | undefined} [origin]
|
|
6526
|
+
* @returns {VFileMessage}
|
|
6527
|
+
*
|
|
6528
|
+
* @overload
|
|
6529
|
+
* @param {Error | VFileMessage} cause
|
|
6530
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6531
|
+
* @param {string | null | undefined} [origin]
|
|
6532
|
+
* @returns {VFileMessage}
|
|
6533
|
+
*
|
|
6534
|
+
* @overload
|
|
6535
|
+
* @param {Error | VFileMessage} cause
|
|
6536
|
+
* @param {Point | Position | null | undefined} place
|
|
6537
|
+
* @param {string | null | undefined} [origin]
|
|
6538
|
+
* @returns {VFileMessage}
|
|
6539
|
+
*
|
|
6540
|
+
* @overload
|
|
6541
|
+
* @param {Error | VFileMessage} cause
|
|
6542
|
+
* @param {string | null | undefined} [origin]
|
|
6543
|
+
* @returns {VFileMessage}
|
|
6544
|
+
*
|
|
6545
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6546
|
+
* Reason for message, should use markdown.
|
|
6547
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6548
|
+
* Configuration (optional).
|
|
6549
|
+
* @param {string | null | undefined} [origin]
|
|
6550
|
+
* Place in code where the message originates (example:
|
|
6551
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6552
|
+
* @returns {VFileMessage}
|
|
6553
|
+
* Message.
|
|
6554
|
+
*/
|
|
6555
|
+
info(reason: string, options?: Options$5 | null | undefined): VFileMessage;
|
|
6556
|
+
/**
|
|
6557
|
+
* Create an info message for `reason` associated with the file.
|
|
6558
|
+
*
|
|
6559
|
+
* The `fatal` field of the message is set to `undefined` (info; change
|
|
6560
|
+
* likely not needed) and the `file` field is set to the current file path.
|
|
6561
|
+
* The message is added to the `messages` field on `file`.
|
|
6562
|
+
*
|
|
6563
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6564
|
+
*
|
|
6565
|
+
* @overload
|
|
6566
|
+
* @param {string} reason
|
|
6567
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6568
|
+
* @returns {VFileMessage}
|
|
6569
|
+
*
|
|
6570
|
+
* @overload
|
|
6571
|
+
* @param {string} reason
|
|
6572
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6573
|
+
* @param {string | null | undefined} [origin]
|
|
6574
|
+
* @returns {VFileMessage}
|
|
6575
|
+
*
|
|
6576
|
+
* @overload
|
|
6577
|
+
* @param {string} reason
|
|
6578
|
+
* @param {Point | Position | null | undefined} place
|
|
6579
|
+
* @param {string | null | undefined} [origin]
|
|
6580
|
+
* @returns {VFileMessage}
|
|
6581
|
+
*
|
|
6582
|
+
* @overload
|
|
6583
|
+
* @param {string} reason
|
|
6584
|
+
* @param {string | null | undefined} [origin]
|
|
6585
|
+
* @returns {VFileMessage}
|
|
6586
|
+
*
|
|
6587
|
+
* @overload
|
|
6588
|
+
* @param {Error | VFileMessage} cause
|
|
6589
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6590
|
+
* @param {string | null | undefined} [origin]
|
|
6591
|
+
* @returns {VFileMessage}
|
|
6592
|
+
*
|
|
6593
|
+
* @overload
|
|
6594
|
+
* @param {Error | VFileMessage} cause
|
|
6595
|
+
* @param {Point | Position | null | undefined} place
|
|
6596
|
+
* @param {string | null | undefined} [origin]
|
|
6597
|
+
* @returns {VFileMessage}
|
|
6598
|
+
*
|
|
6599
|
+
* @overload
|
|
6600
|
+
* @param {Error | VFileMessage} cause
|
|
6601
|
+
* @param {string | null | undefined} [origin]
|
|
6602
|
+
* @returns {VFileMessage}
|
|
6603
|
+
*
|
|
6604
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6605
|
+
* Reason for message, should use markdown.
|
|
6606
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6607
|
+
* Configuration (optional).
|
|
6608
|
+
* @param {string | null | undefined} [origin]
|
|
6609
|
+
* Place in code where the message originates (example:
|
|
6610
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6611
|
+
* @returns {VFileMessage}
|
|
6612
|
+
* Message.
|
|
6613
|
+
*/
|
|
6614
|
+
info(reason: string, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
6615
|
+
/**
|
|
6616
|
+
* Create an info message for `reason` associated with the file.
|
|
6617
|
+
*
|
|
6618
|
+
* The `fatal` field of the message is set to `undefined` (info; change
|
|
6619
|
+
* likely not needed) and the `file` field is set to the current file path.
|
|
6620
|
+
* The message is added to the `messages` field on `file`.
|
|
6621
|
+
*
|
|
6622
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6623
|
+
*
|
|
6624
|
+
* @overload
|
|
6625
|
+
* @param {string} reason
|
|
6626
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6627
|
+
* @returns {VFileMessage}
|
|
6628
|
+
*
|
|
6629
|
+
* @overload
|
|
6630
|
+
* @param {string} reason
|
|
6631
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6632
|
+
* @param {string | null | undefined} [origin]
|
|
6633
|
+
* @returns {VFileMessage}
|
|
6634
|
+
*
|
|
6635
|
+
* @overload
|
|
6636
|
+
* @param {string} reason
|
|
6637
|
+
* @param {Point | Position | null | undefined} place
|
|
6638
|
+
* @param {string | null | undefined} [origin]
|
|
6639
|
+
* @returns {VFileMessage}
|
|
6640
|
+
*
|
|
6641
|
+
* @overload
|
|
6642
|
+
* @param {string} reason
|
|
6643
|
+
* @param {string | null | undefined} [origin]
|
|
6644
|
+
* @returns {VFileMessage}
|
|
6645
|
+
*
|
|
6646
|
+
* @overload
|
|
6647
|
+
* @param {Error | VFileMessage} cause
|
|
6648
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6649
|
+
* @param {string | null | undefined} [origin]
|
|
6650
|
+
* @returns {VFileMessage}
|
|
6651
|
+
*
|
|
6652
|
+
* @overload
|
|
6653
|
+
* @param {Error | VFileMessage} cause
|
|
6654
|
+
* @param {Point | Position | null | undefined} place
|
|
6655
|
+
* @param {string | null | undefined} [origin]
|
|
6656
|
+
* @returns {VFileMessage}
|
|
6657
|
+
*
|
|
6658
|
+
* @overload
|
|
6659
|
+
* @param {Error | VFileMessage} cause
|
|
6660
|
+
* @param {string | null | undefined} [origin]
|
|
6661
|
+
* @returns {VFileMessage}
|
|
6662
|
+
*
|
|
6663
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6664
|
+
* Reason for message, should use markdown.
|
|
6665
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6666
|
+
* Configuration (optional).
|
|
6667
|
+
* @param {string | null | undefined} [origin]
|
|
6668
|
+
* Place in code where the message originates (example:
|
|
6669
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6670
|
+
* @returns {VFileMessage}
|
|
6671
|
+
* Message.
|
|
6672
|
+
*/
|
|
6673
|
+
info(reason: string, place: Point$2 | Position$2 | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
6674
|
+
/**
|
|
6675
|
+
* Create an info message for `reason` associated with the file.
|
|
6676
|
+
*
|
|
6677
|
+
* The `fatal` field of the message is set to `undefined` (info; change
|
|
6678
|
+
* likely not needed) and the `file` field is set to the current file path.
|
|
6679
|
+
* The message is added to the `messages` field on `file`.
|
|
6680
|
+
*
|
|
6681
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6682
|
+
*
|
|
6683
|
+
* @overload
|
|
6684
|
+
* @param {string} reason
|
|
6685
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6686
|
+
* @returns {VFileMessage}
|
|
6687
|
+
*
|
|
6688
|
+
* @overload
|
|
6689
|
+
* @param {string} reason
|
|
6690
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6691
|
+
* @param {string | null | undefined} [origin]
|
|
6692
|
+
* @returns {VFileMessage}
|
|
6693
|
+
*
|
|
6694
|
+
* @overload
|
|
6695
|
+
* @param {string} reason
|
|
6696
|
+
* @param {Point | Position | null | undefined} place
|
|
6697
|
+
* @param {string | null | undefined} [origin]
|
|
6698
|
+
* @returns {VFileMessage}
|
|
6699
|
+
*
|
|
6700
|
+
* @overload
|
|
6701
|
+
* @param {string} reason
|
|
6702
|
+
* @param {string | null | undefined} [origin]
|
|
6703
|
+
* @returns {VFileMessage}
|
|
6704
|
+
*
|
|
6705
|
+
* @overload
|
|
6706
|
+
* @param {Error | VFileMessage} cause
|
|
6707
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6708
|
+
* @param {string | null | undefined} [origin]
|
|
6709
|
+
* @returns {VFileMessage}
|
|
6710
|
+
*
|
|
6711
|
+
* @overload
|
|
6712
|
+
* @param {Error | VFileMessage} cause
|
|
6713
|
+
* @param {Point | Position | null | undefined} place
|
|
6714
|
+
* @param {string | null | undefined} [origin]
|
|
6715
|
+
* @returns {VFileMessage}
|
|
6716
|
+
*
|
|
6717
|
+
* @overload
|
|
6718
|
+
* @param {Error | VFileMessage} cause
|
|
6719
|
+
* @param {string | null | undefined} [origin]
|
|
6720
|
+
* @returns {VFileMessage}
|
|
6721
|
+
*
|
|
6722
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6723
|
+
* Reason for message, should use markdown.
|
|
6724
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6725
|
+
* Configuration (optional).
|
|
6726
|
+
* @param {string | null | undefined} [origin]
|
|
6727
|
+
* Place in code where the message originates (example:
|
|
6728
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6729
|
+
* @returns {VFileMessage}
|
|
6730
|
+
* Message.
|
|
6731
|
+
*/
|
|
6732
|
+
info(reason: string, origin?: string | null | undefined): VFileMessage;
|
|
6733
|
+
/**
|
|
6734
|
+
* Create an info message for `reason` associated with the file.
|
|
6735
|
+
*
|
|
6736
|
+
* The `fatal` field of the message is set to `undefined` (info; change
|
|
6737
|
+
* likely not needed) and the `file` field is set to the current file path.
|
|
6738
|
+
* The message is added to the `messages` field on `file`.
|
|
6739
|
+
*
|
|
6740
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6741
|
+
*
|
|
6742
|
+
* @overload
|
|
6743
|
+
* @param {string} reason
|
|
6744
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6745
|
+
* @returns {VFileMessage}
|
|
6746
|
+
*
|
|
6747
|
+
* @overload
|
|
6748
|
+
* @param {string} reason
|
|
6749
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6750
|
+
* @param {string | null | undefined} [origin]
|
|
6751
|
+
* @returns {VFileMessage}
|
|
6752
|
+
*
|
|
6753
|
+
* @overload
|
|
6754
|
+
* @param {string} reason
|
|
6755
|
+
* @param {Point | Position | null | undefined} place
|
|
6756
|
+
* @param {string | null | undefined} [origin]
|
|
6757
|
+
* @returns {VFileMessage}
|
|
6758
|
+
*
|
|
6759
|
+
* @overload
|
|
6760
|
+
* @param {string} reason
|
|
6761
|
+
* @param {string | null | undefined} [origin]
|
|
6762
|
+
* @returns {VFileMessage}
|
|
6763
|
+
*
|
|
6764
|
+
* @overload
|
|
6765
|
+
* @param {Error | VFileMessage} cause
|
|
6766
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6767
|
+
* @param {string | null | undefined} [origin]
|
|
6768
|
+
* @returns {VFileMessage}
|
|
6769
|
+
*
|
|
6770
|
+
* @overload
|
|
6771
|
+
* @param {Error | VFileMessage} cause
|
|
6772
|
+
* @param {Point | Position | null | undefined} place
|
|
6773
|
+
* @param {string | null | undefined} [origin]
|
|
6774
|
+
* @returns {VFileMessage}
|
|
6775
|
+
*
|
|
6776
|
+
* @overload
|
|
6777
|
+
* @param {Error | VFileMessage} cause
|
|
6778
|
+
* @param {string | null | undefined} [origin]
|
|
6779
|
+
* @returns {VFileMessage}
|
|
6780
|
+
*
|
|
6781
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6782
|
+
* Reason for message, should use markdown.
|
|
6783
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6784
|
+
* Configuration (optional).
|
|
6785
|
+
* @param {string | null | undefined} [origin]
|
|
6786
|
+
* Place in code where the message originates (example:
|
|
6787
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6788
|
+
* @returns {VFileMessage}
|
|
6789
|
+
* Message.
|
|
6790
|
+
*/
|
|
6791
|
+
info(cause: Error | VFileMessage, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
6792
|
+
/**
|
|
6793
|
+
* Create an info message for `reason` associated with the file.
|
|
6794
|
+
*
|
|
6795
|
+
* The `fatal` field of the message is set to `undefined` (info; change
|
|
6796
|
+
* likely not needed) and the `file` field is set to the current file path.
|
|
6797
|
+
* The message is added to the `messages` field on `file`.
|
|
6798
|
+
*
|
|
6799
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6800
|
+
*
|
|
6801
|
+
* @overload
|
|
6802
|
+
* @param {string} reason
|
|
6803
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6804
|
+
* @returns {VFileMessage}
|
|
6805
|
+
*
|
|
6806
|
+
* @overload
|
|
6807
|
+
* @param {string} reason
|
|
6808
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6809
|
+
* @param {string | null | undefined} [origin]
|
|
6810
|
+
* @returns {VFileMessage}
|
|
6811
|
+
*
|
|
6812
|
+
* @overload
|
|
6813
|
+
* @param {string} reason
|
|
6814
|
+
* @param {Point | Position | null | undefined} place
|
|
6815
|
+
* @param {string | null | undefined} [origin]
|
|
6816
|
+
* @returns {VFileMessage}
|
|
6817
|
+
*
|
|
6818
|
+
* @overload
|
|
6819
|
+
* @param {string} reason
|
|
6820
|
+
* @param {string | null | undefined} [origin]
|
|
6821
|
+
* @returns {VFileMessage}
|
|
6822
|
+
*
|
|
6823
|
+
* @overload
|
|
6824
|
+
* @param {Error | VFileMessage} cause
|
|
6825
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6826
|
+
* @param {string | null | undefined} [origin]
|
|
6827
|
+
* @returns {VFileMessage}
|
|
6828
|
+
*
|
|
6829
|
+
* @overload
|
|
6830
|
+
* @param {Error | VFileMessage} cause
|
|
6831
|
+
* @param {Point | Position | null | undefined} place
|
|
6832
|
+
* @param {string | null | undefined} [origin]
|
|
6833
|
+
* @returns {VFileMessage}
|
|
6834
|
+
*
|
|
6835
|
+
* @overload
|
|
6836
|
+
* @param {Error | VFileMessage} cause
|
|
6837
|
+
* @param {string | null | undefined} [origin]
|
|
6838
|
+
* @returns {VFileMessage}
|
|
6839
|
+
*
|
|
6840
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6841
|
+
* Reason for message, should use markdown.
|
|
6842
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6843
|
+
* Configuration (optional).
|
|
6844
|
+
* @param {string | null | undefined} [origin]
|
|
6845
|
+
* Place in code where the message originates (example:
|
|
6846
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6847
|
+
* @returns {VFileMessage}
|
|
6848
|
+
* Message.
|
|
6849
|
+
*/
|
|
6850
|
+
info(cause: Error | VFileMessage, place: Point$2 | Position$2 | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
6851
|
+
/**
|
|
6852
|
+
* Create an info message for `reason` associated with the file.
|
|
6853
|
+
*
|
|
6854
|
+
* The `fatal` field of the message is set to `undefined` (info; change
|
|
6855
|
+
* likely not needed) and the `file` field is set to the current file path.
|
|
6856
|
+
* The message is added to the `messages` field on `file`.
|
|
6857
|
+
*
|
|
6858
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6859
|
+
*
|
|
6860
|
+
* @overload
|
|
6861
|
+
* @param {string} reason
|
|
6862
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6863
|
+
* @returns {VFileMessage}
|
|
6864
|
+
*
|
|
6865
|
+
* @overload
|
|
6866
|
+
* @param {string} reason
|
|
6867
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6868
|
+
* @param {string | null | undefined} [origin]
|
|
6869
|
+
* @returns {VFileMessage}
|
|
6870
|
+
*
|
|
6871
|
+
* @overload
|
|
6872
|
+
* @param {string} reason
|
|
6873
|
+
* @param {Point | Position | null | undefined} place
|
|
6874
|
+
* @param {string | null | undefined} [origin]
|
|
6875
|
+
* @returns {VFileMessage}
|
|
6876
|
+
*
|
|
6877
|
+
* @overload
|
|
6878
|
+
* @param {string} reason
|
|
6879
|
+
* @param {string | null | undefined} [origin]
|
|
6880
|
+
* @returns {VFileMessage}
|
|
6881
|
+
*
|
|
6882
|
+
* @overload
|
|
6883
|
+
* @param {Error | VFileMessage} cause
|
|
6884
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6885
|
+
* @param {string | null | undefined} [origin]
|
|
6886
|
+
* @returns {VFileMessage}
|
|
6887
|
+
*
|
|
6888
|
+
* @overload
|
|
6889
|
+
* @param {Error | VFileMessage} cause
|
|
6890
|
+
* @param {Point | Position | null | undefined} place
|
|
6891
|
+
* @param {string | null | undefined} [origin]
|
|
6892
|
+
* @returns {VFileMessage}
|
|
6893
|
+
*
|
|
6894
|
+
* @overload
|
|
6895
|
+
* @param {Error | VFileMessage} cause
|
|
6896
|
+
* @param {string | null | undefined} [origin]
|
|
6897
|
+
* @returns {VFileMessage}
|
|
6898
|
+
*
|
|
6899
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6900
|
+
* Reason for message, should use markdown.
|
|
6901
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6902
|
+
* Configuration (optional).
|
|
6903
|
+
* @param {string | null | undefined} [origin]
|
|
6904
|
+
* Place in code where the message originates (example:
|
|
6905
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6906
|
+
* @returns {VFileMessage}
|
|
6907
|
+
* Message.
|
|
6908
|
+
*/
|
|
6909
|
+
info(cause: Error | VFileMessage, origin?: string | null | undefined): VFileMessage;
|
|
6910
|
+
/**
|
|
6911
|
+
* Create a message for `reason` associated with the file.
|
|
6912
|
+
*
|
|
6913
|
+
* The `fatal` field of the message is set to `false` (warning; change may be
|
|
6914
|
+
* needed) and the `file` field is set to the current file path.
|
|
6915
|
+
* The message is added to the `messages` field on `file`.
|
|
6916
|
+
*
|
|
6917
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6918
|
+
*
|
|
6919
|
+
* @overload
|
|
6920
|
+
* @param {string} reason
|
|
6921
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6922
|
+
* @returns {VFileMessage}
|
|
6923
|
+
*
|
|
6924
|
+
* @overload
|
|
6925
|
+
* @param {string} reason
|
|
6926
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6927
|
+
* @param {string | null | undefined} [origin]
|
|
6928
|
+
* @returns {VFileMessage}
|
|
6929
|
+
*
|
|
6930
|
+
* @overload
|
|
6931
|
+
* @param {string} reason
|
|
6932
|
+
* @param {Point | Position | null | undefined} place
|
|
6933
|
+
* @param {string | null | undefined} [origin]
|
|
6934
|
+
* @returns {VFileMessage}
|
|
6935
|
+
*
|
|
6936
|
+
* @overload
|
|
6937
|
+
* @param {string} reason
|
|
6938
|
+
* @param {string | null | undefined} [origin]
|
|
6939
|
+
* @returns {VFileMessage}
|
|
6940
|
+
*
|
|
6941
|
+
* @overload
|
|
6942
|
+
* @param {Error | VFileMessage} cause
|
|
6943
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6944
|
+
* @param {string | null | undefined} [origin]
|
|
6945
|
+
* @returns {VFileMessage}
|
|
6946
|
+
*
|
|
6947
|
+
* @overload
|
|
6948
|
+
* @param {Error | VFileMessage} cause
|
|
6949
|
+
* @param {Point | Position | null | undefined} place
|
|
6950
|
+
* @param {string | null | undefined} [origin]
|
|
6951
|
+
* @returns {VFileMessage}
|
|
6952
|
+
*
|
|
6953
|
+
* @overload
|
|
6954
|
+
* @param {Error | VFileMessage} cause
|
|
6955
|
+
* @param {string | null | undefined} [origin]
|
|
6956
|
+
* @returns {VFileMessage}
|
|
6957
|
+
*
|
|
6958
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
6959
|
+
* Reason for message, should use markdown.
|
|
6960
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
6961
|
+
* Configuration (optional).
|
|
6962
|
+
* @param {string | null | undefined} [origin]
|
|
6963
|
+
* Place in code where the message originates (example:
|
|
6964
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
6965
|
+
* @returns {VFileMessage}
|
|
6966
|
+
* Message.
|
|
6967
|
+
*/
|
|
6968
|
+
message(reason: string, options?: Options$5 | null | undefined): VFileMessage;
|
|
6969
|
+
/**
|
|
6970
|
+
* Create a message for `reason` associated with the file.
|
|
6971
|
+
*
|
|
6972
|
+
* The `fatal` field of the message is set to `false` (warning; change may be
|
|
6973
|
+
* needed) and the `file` field is set to the current file path.
|
|
6974
|
+
* The message is added to the `messages` field on `file`.
|
|
6975
|
+
*
|
|
6976
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
6977
|
+
*
|
|
6978
|
+
* @overload
|
|
6979
|
+
* @param {string} reason
|
|
6980
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
6981
|
+
* @returns {VFileMessage}
|
|
6982
|
+
*
|
|
6983
|
+
* @overload
|
|
6984
|
+
* @param {string} reason
|
|
6985
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
6986
|
+
* @param {string | null | undefined} [origin]
|
|
6987
|
+
* @returns {VFileMessage}
|
|
6988
|
+
*
|
|
6989
|
+
* @overload
|
|
6990
|
+
* @param {string} reason
|
|
6991
|
+
* @param {Point | Position | null | undefined} place
|
|
6992
|
+
* @param {string | null | undefined} [origin]
|
|
6993
|
+
* @returns {VFileMessage}
|
|
6994
|
+
*
|
|
6995
|
+
* @overload
|
|
6996
|
+
* @param {string} reason
|
|
6997
|
+
* @param {string | null | undefined} [origin]
|
|
6998
|
+
* @returns {VFileMessage}
|
|
6999
|
+
*
|
|
7000
|
+
* @overload
|
|
7001
|
+
* @param {Error | VFileMessage} cause
|
|
7002
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7003
|
+
* @param {string | null | undefined} [origin]
|
|
7004
|
+
* @returns {VFileMessage}
|
|
7005
|
+
*
|
|
7006
|
+
* @overload
|
|
7007
|
+
* @param {Error | VFileMessage} cause
|
|
7008
|
+
* @param {Point | Position | null | undefined} place
|
|
7009
|
+
* @param {string | null | undefined} [origin]
|
|
7010
|
+
* @returns {VFileMessage}
|
|
7011
|
+
*
|
|
7012
|
+
* @overload
|
|
7013
|
+
* @param {Error | VFileMessage} cause
|
|
7014
|
+
* @param {string | null | undefined} [origin]
|
|
7015
|
+
* @returns {VFileMessage}
|
|
7016
|
+
*
|
|
7017
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
7018
|
+
* Reason for message, should use markdown.
|
|
7019
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
7020
|
+
* Configuration (optional).
|
|
7021
|
+
* @param {string | null | undefined} [origin]
|
|
7022
|
+
* Place in code where the message originates (example:
|
|
7023
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
7024
|
+
* @returns {VFileMessage}
|
|
7025
|
+
* Message.
|
|
7026
|
+
*/
|
|
7027
|
+
message(reason: string, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
7028
|
+
/**
|
|
7029
|
+
* Create a message for `reason` associated with the file.
|
|
7030
|
+
*
|
|
7031
|
+
* The `fatal` field of the message is set to `false` (warning; change may be
|
|
7032
|
+
* needed) and the `file` field is set to the current file path.
|
|
7033
|
+
* The message is added to the `messages` field on `file`.
|
|
7034
|
+
*
|
|
7035
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
7036
|
+
*
|
|
7037
|
+
* @overload
|
|
7038
|
+
* @param {string} reason
|
|
7039
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
7040
|
+
* @returns {VFileMessage}
|
|
7041
|
+
*
|
|
7042
|
+
* @overload
|
|
7043
|
+
* @param {string} reason
|
|
7044
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7045
|
+
* @param {string | null | undefined} [origin]
|
|
7046
|
+
* @returns {VFileMessage}
|
|
7047
|
+
*
|
|
7048
|
+
* @overload
|
|
7049
|
+
* @param {string} reason
|
|
7050
|
+
* @param {Point | Position | null | undefined} place
|
|
7051
|
+
* @param {string | null | undefined} [origin]
|
|
7052
|
+
* @returns {VFileMessage}
|
|
7053
|
+
*
|
|
7054
|
+
* @overload
|
|
7055
|
+
* @param {string} reason
|
|
7056
|
+
* @param {string | null | undefined} [origin]
|
|
7057
|
+
* @returns {VFileMessage}
|
|
7058
|
+
*
|
|
7059
|
+
* @overload
|
|
7060
|
+
* @param {Error | VFileMessage} cause
|
|
7061
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7062
|
+
* @param {string | null | undefined} [origin]
|
|
7063
|
+
* @returns {VFileMessage}
|
|
7064
|
+
*
|
|
7065
|
+
* @overload
|
|
7066
|
+
* @param {Error | VFileMessage} cause
|
|
7067
|
+
* @param {Point | Position | null | undefined} place
|
|
7068
|
+
* @param {string | null | undefined} [origin]
|
|
7069
|
+
* @returns {VFileMessage}
|
|
7070
|
+
*
|
|
7071
|
+
* @overload
|
|
7072
|
+
* @param {Error | VFileMessage} cause
|
|
7073
|
+
* @param {string | null | undefined} [origin]
|
|
7074
|
+
* @returns {VFileMessage}
|
|
7075
|
+
*
|
|
7076
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
7077
|
+
* Reason for message, should use markdown.
|
|
7078
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
7079
|
+
* Configuration (optional).
|
|
7080
|
+
* @param {string | null | undefined} [origin]
|
|
7081
|
+
* Place in code where the message originates (example:
|
|
7082
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
7083
|
+
* @returns {VFileMessage}
|
|
7084
|
+
* Message.
|
|
7085
|
+
*/
|
|
7086
|
+
message(reason: string, place: Point$2 | Position$2 | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
7087
|
+
/**
|
|
7088
|
+
* Create a message for `reason` associated with the file.
|
|
7089
|
+
*
|
|
7090
|
+
* The `fatal` field of the message is set to `false` (warning; change may be
|
|
7091
|
+
* needed) and the `file` field is set to the current file path.
|
|
7092
|
+
* The message is added to the `messages` field on `file`.
|
|
7093
|
+
*
|
|
7094
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
7095
|
+
*
|
|
7096
|
+
* @overload
|
|
7097
|
+
* @param {string} reason
|
|
7098
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
7099
|
+
* @returns {VFileMessage}
|
|
7100
|
+
*
|
|
7101
|
+
* @overload
|
|
7102
|
+
* @param {string} reason
|
|
7103
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7104
|
+
* @param {string | null | undefined} [origin]
|
|
7105
|
+
* @returns {VFileMessage}
|
|
7106
|
+
*
|
|
7107
|
+
* @overload
|
|
7108
|
+
* @param {string} reason
|
|
7109
|
+
* @param {Point | Position | null | undefined} place
|
|
7110
|
+
* @param {string | null | undefined} [origin]
|
|
7111
|
+
* @returns {VFileMessage}
|
|
7112
|
+
*
|
|
7113
|
+
* @overload
|
|
7114
|
+
* @param {string} reason
|
|
7115
|
+
* @param {string | null | undefined} [origin]
|
|
7116
|
+
* @returns {VFileMessage}
|
|
7117
|
+
*
|
|
7118
|
+
* @overload
|
|
7119
|
+
* @param {Error | VFileMessage} cause
|
|
7120
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7121
|
+
* @param {string | null | undefined} [origin]
|
|
7122
|
+
* @returns {VFileMessage}
|
|
7123
|
+
*
|
|
7124
|
+
* @overload
|
|
7125
|
+
* @param {Error | VFileMessage} cause
|
|
7126
|
+
* @param {Point | Position | null | undefined} place
|
|
7127
|
+
* @param {string | null | undefined} [origin]
|
|
7128
|
+
* @returns {VFileMessage}
|
|
7129
|
+
*
|
|
7130
|
+
* @overload
|
|
7131
|
+
* @param {Error | VFileMessage} cause
|
|
7132
|
+
* @param {string | null | undefined} [origin]
|
|
7133
|
+
* @returns {VFileMessage}
|
|
7134
|
+
*
|
|
7135
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
7136
|
+
* Reason for message, should use markdown.
|
|
7137
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
7138
|
+
* Configuration (optional).
|
|
7139
|
+
* @param {string | null | undefined} [origin]
|
|
7140
|
+
* Place in code where the message originates (example:
|
|
7141
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
7142
|
+
* @returns {VFileMessage}
|
|
7143
|
+
* Message.
|
|
7144
|
+
*/
|
|
7145
|
+
message(reason: string, origin?: string | null | undefined): VFileMessage;
|
|
7146
|
+
/**
|
|
7147
|
+
* Create a message for `reason` associated with the file.
|
|
7148
|
+
*
|
|
7149
|
+
* The `fatal` field of the message is set to `false` (warning; change may be
|
|
7150
|
+
* needed) and the `file` field is set to the current file path.
|
|
7151
|
+
* The message is added to the `messages` field on `file`.
|
|
7152
|
+
*
|
|
7153
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
7154
|
+
*
|
|
7155
|
+
* @overload
|
|
7156
|
+
* @param {string} reason
|
|
7157
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
7158
|
+
* @returns {VFileMessage}
|
|
7159
|
+
*
|
|
7160
|
+
* @overload
|
|
7161
|
+
* @param {string} reason
|
|
7162
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7163
|
+
* @param {string | null | undefined} [origin]
|
|
7164
|
+
* @returns {VFileMessage}
|
|
7165
|
+
*
|
|
7166
|
+
* @overload
|
|
7167
|
+
* @param {string} reason
|
|
7168
|
+
* @param {Point | Position | null | undefined} place
|
|
7169
|
+
* @param {string | null | undefined} [origin]
|
|
7170
|
+
* @returns {VFileMessage}
|
|
7171
|
+
*
|
|
7172
|
+
* @overload
|
|
7173
|
+
* @param {string} reason
|
|
7174
|
+
* @param {string | null | undefined} [origin]
|
|
7175
|
+
* @returns {VFileMessage}
|
|
7176
|
+
*
|
|
7177
|
+
* @overload
|
|
7178
|
+
* @param {Error | VFileMessage} cause
|
|
7179
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7180
|
+
* @param {string | null | undefined} [origin]
|
|
7181
|
+
* @returns {VFileMessage}
|
|
7182
|
+
*
|
|
7183
|
+
* @overload
|
|
7184
|
+
* @param {Error | VFileMessage} cause
|
|
7185
|
+
* @param {Point | Position | null | undefined} place
|
|
7186
|
+
* @param {string | null | undefined} [origin]
|
|
7187
|
+
* @returns {VFileMessage}
|
|
7188
|
+
*
|
|
7189
|
+
* @overload
|
|
7190
|
+
* @param {Error | VFileMessage} cause
|
|
7191
|
+
* @param {string | null | undefined} [origin]
|
|
7192
|
+
* @returns {VFileMessage}
|
|
7193
|
+
*
|
|
7194
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
7195
|
+
* Reason for message, should use markdown.
|
|
7196
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
7197
|
+
* Configuration (optional).
|
|
7198
|
+
* @param {string | null | undefined} [origin]
|
|
7199
|
+
* Place in code where the message originates (example:
|
|
7200
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
7201
|
+
* @returns {VFileMessage}
|
|
7202
|
+
* Message.
|
|
7203
|
+
*/
|
|
7204
|
+
message(cause: Error | VFileMessage, parent: Node$2 | NodeLike | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
7205
|
+
/**
|
|
7206
|
+
* Create a message for `reason` associated with the file.
|
|
7207
|
+
*
|
|
7208
|
+
* The `fatal` field of the message is set to `false` (warning; change may be
|
|
7209
|
+
* needed) and the `file` field is set to the current file path.
|
|
7210
|
+
* The message is added to the `messages` field on `file`.
|
|
7211
|
+
*
|
|
7212
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
7213
|
+
*
|
|
7214
|
+
* @overload
|
|
7215
|
+
* @param {string} reason
|
|
7216
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
7217
|
+
* @returns {VFileMessage}
|
|
7218
|
+
*
|
|
7219
|
+
* @overload
|
|
7220
|
+
* @param {string} reason
|
|
7221
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7222
|
+
* @param {string | null | undefined} [origin]
|
|
7223
|
+
* @returns {VFileMessage}
|
|
7224
|
+
*
|
|
7225
|
+
* @overload
|
|
7226
|
+
* @param {string} reason
|
|
7227
|
+
* @param {Point | Position | null | undefined} place
|
|
7228
|
+
* @param {string | null | undefined} [origin]
|
|
7229
|
+
* @returns {VFileMessage}
|
|
7230
|
+
*
|
|
7231
|
+
* @overload
|
|
7232
|
+
* @param {string} reason
|
|
7233
|
+
* @param {string | null | undefined} [origin]
|
|
7234
|
+
* @returns {VFileMessage}
|
|
7235
|
+
*
|
|
7236
|
+
* @overload
|
|
7237
|
+
* @param {Error | VFileMessage} cause
|
|
7238
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7239
|
+
* @param {string | null | undefined} [origin]
|
|
7240
|
+
* @returns {VFileMessage}
|
|
7241
|
+
*
|
|
7242
|
+
* @overload
|
|
7243
|
+
* @param {Error | VFileMessage} cause
|
|
7244
|
+
* @param {Point | Position | null | undefined} place
|
|
7245
|
+
* @param {string | null | undefined} [origin]
|
|
7246
|
+
* @returns {VFileMessage}
|
|
7247
|
+
*
|
|
7248
|
+
* @overload
|
|
7249
|
+
* @param {Error | VFileMessage} cause
|
|
7250
|
+
* @param {string | null | undefined} [origin]
|
|
7251
|
+
* @returns {VFileMessage}
|
|
7252
|
+
*
|
|
7253
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
7254
|
+
* Reason for message, should use markdown.
|
|
7255
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
7256
|
+
* Configuration (optional).
|
|
7257
|
+
* @param {string | null | undefined} [origin]
|
|
7258
|
+
* Place in code where the message originates (example:
|
|
7259
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
7260
|
+
* @returns {VFileMessage}
|
|
7261
|
+
* Message.
|
|
7262
|
+
*/
|
|
7263
|
+
message(cause: Error | VFileMessage, place: Point$2 | Position$2 | null | undefined, origin?: string | null | undefined): VFileMessage;
|
|
7264
|
+
/**
|
|
7265
|
+
* Create a message for `reason` associated with the file.
|
|
7266
|
+
*
|
|
7267
|
+
* The `fatal` field of the message is set to `false` (warning; change may be
|
|
7268
|
+
* needed) and the `file` field is set to the current file path.
|
|
7269
|
+
* The message is added to the `messages` field on `file`.
|
|
7270
|
+
*
|
|
7271
|
+
* > 🪦 **Note**: also has obsolete signatures.
|
|
7272
|
+
*
|
|
7273
|
+
* @overload
|
|
7274
|
+
* @param {string} reason
|
|
7275
|
+
* @param {MessageOptions | null | undefined} [options]
|
|
7276
|
+
* @returns {VFileMessage}
|
|
7277
|
+
*
|
|
7278
|
+
* @overload
|
|
7279
|
+
* @param {string} reason
|
|
7280
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7281
|
+
* @param {string | null | undefined} [origin]
|
|
7282
|
+
* @returns {VFileMessage}
|
|
7283
|
+
*
|
|
7284
|
+
* @overload
|
|
7285
|
+
* @param {string} reason
|
|
7286
|
+
* @param {Point | Position | null | undefined} place
|
|
7287
|
+
* @param {string | null | undefined} [origin]
|
|
7288
|
+
* @returns {VFileMessage}
|
|
7289
|
+
*
|
|
7290
|
+
* @overload
|
|
7291
|
+
* @param {string} reason
|
|
7292
|
+
* @param {string | null | undefined} [origin]
|
|
7293
|
+
* @returns {VFileMessage}
|
|
7294
|
+
*
|
|
7295
|
+
* @overload
|
|
7296
|
+
* @param {Error | VFileMessage} cause
|
|
7297
|
+
* @param {Node | NodeLike | null | undefined} parent
|
|
7298
|
+
* @param {string | null | undefined} [origin]
|
|
7299
|
+
* @returns {VFileMessage}
|
|
7300
|
+
*
|
|
7301
|
+
* @overload
|
|
7302
|
+
* @param {Error | VFileMessage} cause
|
|
7303
|
+
* @param {Point | Position | null | undefined} place
|
|
7304
|
+
* @param {string | null | undefined} [origin]
|
|
7305
|
+
* @returns {VFileMessage}
|
|
7306
|
+
*
|
|
7307
|
+
* @overload
|
|
7308
|
+
* @param {Error | VFileMessage} cause
|
|
7309
|
+
* @param {string | null | undefined} [origin]
|
|
7310
|
+
* @returns {VFileMessage}
|
|
7311
|
+
*
|
|
7312
|
+
* @param {Error | VFileMessage | string} causeOrReason
|
|
7313
|
+
* Reason for message, should use markdown.
|
|
7314
|
+
* @param {Node | NodeLike | MessageOptions | Point | Position | string | null | undefined} [optionsOrParentOrPlace]
|
|
7315
|
+
* Configuration (optional).
|
|
7316
|
+
* @param {string | null | undefined} [origin]
|
|
7317
|
+
* Place in code where the message originates (example:
|
|
7318
|
+
* `'my-package:my-rule'` or `'my-rule'`).
|
|
7319
|
+
* @returns {VFileMessage}
|
|
7320
|
+
* Message.
|
|
7321
|
+
*/
|
|
7322
|
+
message(cause: Error | VFileMessage, origin?: string | null | undefined): VFileMessage;
|
|
7323
|
+
/**
|
|
7324
|
+
* Serialize the file.
|
|
7325
|
+
*
|
|
7326
|
+
* > **Note**: which encodings are supported depends on the engine.
|
|
7327
|
+
* > For info on Node.js, see:
|
|
7328
|
+
* > <https://nodejs.org/api/util.html#whatwg-supported-encodings>.
|
|
7329
|
+
*
|
|
7330
|
+
* @param {string | null | undefined} [encoding='utf8']
|
|
7331
|
+
* Character encoding to understand `value` as when it’s a `Uint8Array`
|
|
7332
|
+
* (default: `'utf-8'`).
|
|
7333
|
+
* @returns {string}
|
|
7334
|
+
* Serialized file.
|
|
7335
|
+
*/
|
|
7336
|
+
toString(encoding?: string | null | undefined): string;
|
|
7337
|
+
}
|
|
7338
|
+
type NodeLike = object & {
|
|
7339
|
+
type: string;
|
|
7340
|
+
position?: Position$2 | undefined;
|
|
7341
|
+
};
|
|
7342
|
+
|
|
7343
|
+
// See: <https://github.com/sindresorhus/type-fest/blob/main/source/empty-object.d.ts>
|
|
7344
|
+
declare const emptyObjectSymbol: unique symbol
|
|
7345
|
+
|
|
7346
|
+
|
|
7347
|
+
/**
|
|
7348
|
+
* Things that can be passed to the constructor.
|
|
7349
|
+
*/
|
|
7350
|
+
type Compatible$1 = Options | URL | VFile$1 | Value
|
|
7351
|
+
|
|
7352
|
+
/**
|
|
7353
|
+
* Raw source map.
|
|
7354
|
+
*
|
|
7355
|
+
* See:
|
|
7356
|
+
* <https://github.com/mozilla/source-map/blob/60adcb0/source-map.d.ts#L15-L23>.
|
|
7357
|
+
*/
|
|
7358
|
+
interface Map$1 {
|
|
7359
|
+
/**
|
|
7360
|
+
* The generated file this source map is associated with.
|
|
7361
|
+
*/
|
|
7362
|
+
file: string
|
|
7363
|
+
/**
|
|
7364
|
+
* A string of base64 VLQs which contain the actual mappings.
|
|
7365
|
+
*/
|
|
7366
|
+
mappings: string
|
|
7367
|
+
/**
|
|
7368
|
+
* An array of identifiers which can be referenced by individual mappings.
|
|
7369
|
+
*/
|
|
7370
|
+
names: Array<string>
|
|
7371
|
+
/**
|
|
7372
|
+
* An array of contents of the original source files.
|
|
7373
|
+
*/
|
|
7374
|
+
sourcesContent?: Array<string> | undefined
|
|
7375
|
+
/**
|
|
7376
|
+
* The URL root from which all sources are relative.
|
|
7377
|
+
*/
|
|
7378
|
+
sourceRoot?: string | undefined
|
|
7379
|
+
/**
|
|
7380
|
+
* An array of URLs to the original source files.
|
|
7381
|
+
*/
|
|
7382
|
+
sources: Array<string>
|
|
7383
|
+
/**
|
|
7384
|
+
* Which version of the source map spec this map is following.
|
|
7385
|
+
*/
|
|
7386
|
+
version: number
|
|
7387
|
+
}
|
|
7388
|
+
|
|
7389
|
+
/**
|
|
7390
|
+
* This map registers the type of the `data` key of a `VFile`.
|
|
7391
|
+
*
|
|
7392
|
+
* This type can be augmented to register custom `data` types.
|
|
7393
|
+
*
|
|
7394
|
+
* @example
|
|
7395
|
+
* declare module 'vfile' {
|
|
7396
|
+
* interface DataMap {
|
|
7397
|
+
* // `file.data.name` is typed as `string`
|
|
7398
|
+
* name: string
|
|
7399
|
+
* }
|
|
7400
|
+
* }
|
|
7401
|
+
*/
|
|
7402
|
+
interface DataMap {
|
|
7403
|
+
[emptyObjectSymbol]?: never
|
|
7404
|
+
}
|
|
7405
|
+
|
|
7406
|
+
/**
|
|
7407
|
+
* Custom info.
|
|
7408
|
+
*
|
|
7409
|
+
* Known attributes can be added to {@linkcode DataMap}
|
|
7410
|
+
*/
|
|
7411
|
+
type Data = Record<string, unknown> & Partial<DataMap>
|
|
7412
|
+
|
|
7413
|
+
/**
|
|
7414
|
+
* Configuration.
|
|
7415
|
+
*/
|
|
7416
|
+
interface Options {
|
|
7417
|
+
/**
|
|
7418
|
+
* Arbitrary fields that will be shallow copied over to the new file.
|
|
7419
|
+
*/
|
|
7420
|
+
[key: string]: unknown
|
|
7421
|
+
/**
|
|
7422
|
+
* Set `basename` (name).
|
|
7423
|
+
*/
|
|
7424
|
+
basename?: string | null | undefined
|
|
7425
|
+
/**
|
|
7426
|
+
* Set `cwd` (working directory).
|
|
7427
|
+
*/
|
|
7428
|
+
cwd?: string | null | undefined
|
|
7429
|
+
/**
|
|
7430
|
+
* Set `data` (associated info).
|
|
7431
|
+
*/
|
|
7432
|
+
data?: Data | null | undefined
|
|
7433
|
+
/**
|
|
7434
|
+
* Set `dirname` (path w/o basename).
|
|
7435
|
+
*/
|
|
7436
|
+
dirname?: string | null | undefined
|
|
7437
|
+
/**
|
|
7438
|
+
* Set `extname` (extension with dot).
|
|
7439
|
+
*/
|
|
7440
|
+
extname?: string | null | undefined
|
|
7441
|
+
/**
|
|
7442
|
+
* Set `history` (paths the file moved between).
|
|
7443
|
+
*/
|
|
7444
|
+
history?: Array<string> | null | undefined
|
|
7445
|
+
/**
|
|
7446
|
+
* Set `path` (current path).
|
|
7447
|
+
*/
|
|
7448
|
+
path?: URL | string | null | undefined
|
|
7449
|
+
/**
|
|
7450
|
+
* Set `stem` (name without extension).
|
|
7451
|
+
*/
|
|
7452
|
+
stem?: string | null | undefined
|
|
7453
|
+
/**
|
|
7454
|
+
* Set `value` (the contents of the file).
|
|
7455
|
+
*/
|
|
7456
|
+
value?: Value | null | undefined
|
|
7457
|
+
}
|
|
7458
|
+
|
|
7459
|
+
/**
|
|
7460
|
+
* Contents of the file.
|
|
7461
|
+
*
|
|
7462
|
+
* Can either be text or a `Uint8Array` structure.
|
|
7463
|
+
*/
|
|
7464
|
+
type Value = Uint8Array | string
|
|
7465
|
+
|
|
5887
7466
|
/**
|
|
5888
7467
|
* Compile MDX to JS.
|
|
5889
7468
|
*
|
|
@@ -5896,7 +7475,7 @@ type ProcessorOptions$1 = {
|
|
|
5896
7475
|
*/
|
|
5897
7476
|
declare function compile(vfileCompatible: Readonly<Compatible>, compileOptions?: Readonly<CompileOptions$1> | null | undefined): Promise<VFile>;
|
|
5898
7477
|
type VFile = VFile$1;
|
|
5899
|
-
type Compatible = Compatible$
|
|
7478
|
+
type Compatible = Compatible$1;
|
|
5900
7479
|
type ProcessorOptions = ProcessorOptions$1;
|
|
5901
7480
|
/**
|
|
5902
7481
|
* Core configuration.
|