Skip to content

Commit 7148746

Browse files
committed
Refactor docs
1 parent a44db46 commit 7148746

File tree

5 files changed

+1025
-655
lines changed

5 files changed

+1025
-655
lines changed

index.d.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type {VFileValue} from 'vfile'
1+
import type {Value} from 'vfile'
22
import type {CompileResults} from './lib/index.js'
33

44
export type {
@@ -8,13 +8,13 @@ export type {
88
CompilerClass,
99
CompilerFunction,
1010
// `Data` is typed and exposed below.
11+
Parser,
12+
ParserClass,
13+
ParserFunction,
1114
Pluggable,
1215
PluggableList,
1316
Plugin,
1417
PluginTuple,
15-
Parser,
16-
ParserClass,
17-
ParserFunction,
1818
Preset,
1919
ProcessCallback,
2020
Processor,
@@ -29,7 +29,7 @@ export {unified} from './lib/index.js'
2929
/**
3030
* Interface of known results from compilers.
3131
*
32-
* Normally, compilers result in text ({@link VFileValue `VFileValue`}).
32+
* Normally, compilers result in text ({@link Value `Value`} of `vfile`).
3333
* When you compile to something else, such as a React node (as in,
3434
* `rehype-react`), you can augment this interface to include that type.
3535
*

index.test-d.ts

+4
Original file line numberDiff line numberDiff line change
@@ -477,6 +477,10 @@ declare module './index.js' {
477477
interface CompileResultMap {
478478
ReactNode: ReactNode
479479
}
480+
481+
interface Data {
482+
something?: string | undefined
483+
}
480484
}
481485

482486
// Compile plugin (to a non-node).

0 commit comments

Comments
 (0)