Skip to content

Commit f163eb0

Browse files
committed
Refactor docs
1 parent 9a57d62 commit f163eb0

File tree

1 file changed

+23
-20
lines changed

1 file changed

+23
-20
lines changed

readme.md

Lines changed: 23 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ anything from callouts, citations, styled blocks, forms, embeds, spoilers, etc.
8282
## Install
8383

8484
This package is [ESM only][esm].
85-
In Node.js (version 14.14+ and 16.0+), install with [npm][]:
85+
In Node.js (version 16+), install with [npm][]:
8686

8787
```sh
8888
npm install mdast-util-directive
@@ -163,19 +163,19 @@ A lovely language know as :abbr[HTML]{title="HyperText Markup Language"}.
163163
## API
164164

165165
This package exports the identifiers
166-
[`directiveFromMarkdown`][api-directivefrommarkdown] and
167-
[`directiveToMarkdown`][api-directivetomarkdown].
166+
[`directiveFromMarkdown`][api-directive-from-markdown] and
167+
[`directiveToMarkdown`][api-directive-to-markdown].
168168
There is no default export.
169169

170170
### `directiveFromMarkdown`
171171

172172
Extension for [`mdast-util-from-markdown`][mdast-util-from-markdown] to enable
173-
directives ([`FromMarkdownExtension`][frommarkdownextension]).
173+
directives ([`FromMarkdownExtension`][from-markdown-extension]).
174174

175175
### `directiveToMarkdown`
176176

177177
Extension for [`mdast-util-to-markdown`][mdast-util-to-markdown] to enable
178-
directives ([`ToMarkdownExtension`][tomarkdownextension]).
178+
directives ([`ToMarkdownExtension`][to-markdown-extension]).
179179

180180
There are no options, but passing [`options.quote`][quote] to
181181
`mdast-util-to-markdown` is honored for attributes.
@@ -409,9 +409,9 @@ or hast).
409409
## Types
410410

411411
This package is fully typed with [TypeScript][].
412-
It exports the additional types [`ContainerDirective`][api-containerdirective],
413-
[`Directive`][api-directive], [`LeafDirective`][api-leafdirective], and
414-
[`TextDirective`][api-textdirective].
412+
It exports the additional types [`ContainerDirective`][api-container-directive],
413+
[`Directive`][api-directive], [`LeafDirective`][api-leaf-directive], and
414+
[`TextDirective`][api-text-directive].
415415

416416
It also registers the node types with `@types/mdast`.
417417
If you’re working with the syntax tree, make sure to import this utility
@@ -434,10 +434,13 @@ visit(tree, function (node) {
434434

435435
## Compatibility
436436

437-
Projects maintained by the unified collective are compatible with all maintained
437+
Projects maintained by the unified collective are compatible with maintained
438438
versions of Node.js.
439-
As of now, that is Node.js 14.14+ and 16.0+.
440-
Our projects sometimes work with older versions, but this is not guaranteed.
439+
440+
When we cut a new major release, we drop support for unmaintained versions of
441+
Node.
442+
This means we try to keep the current release line, `mdast-util-directive@^2`,
443+
compatible with Node.js 12.
441444

442445
This plugin works with `mdast-util-from-markdown` version 1+ and
443446
`mdast-util-to-markdown` version 1+.
@@ -477,9 +480,9 @@ abide by its terms.
477480

478481
[downloads]: https://www.npmjs.com/package/mdast-util-directive
479482

480-
[size-badge]: https://img.shields.io/bundlephobia/minzip/mdast-util-directive.svg
483+
[size-badge]: https://img.shields.io/badge/dynamic/json?label=minzipped%20size&query=$.size.compressedSize&url=https://deno.bundlejs.com/?q=mdast-util-directive
481484

482-
[size]: https://bundlephobia.com/result?p=mdast-util-directive
485+
[size]: https://bundlejs.com/?q=mdast-util-directive
483486

484487
[sponsors-badge]: https://opencollective.com/unified/sponsors/badge.svg
485488

@@ -539,20 +542,20 @@ abide by its terms.
539542

540543
[dfn-phrasing-content]: https://github.com/syntax-tree/mdast#phrasingcontent
541544

542-
[frommarkdownextension]: https://github.com/syntax-tree/mdast-util-from-markdown#extension
545+
[from-markdown-extension]: https://github.com/syntax-tree/mdast-util-from-markdown#extension
543546

544-
[tomarkdownextension]: https://github.com/syntax-tree/mdast-util-to-markdown#options
547+
[to-markdown-extension]: https://github.com/syntax-tree/mdast-util-to-markdown#options
545548

546-
[api-directivefrommarkdown]: #directivefrommarkdown
549+
[api-directive-from-markdown]: #directivefrommarkdown
547550

548-
[api-directivetomarkdown]: #directivetomarkdown
551+
[api-directive-to-markdown]: #directivetomarkdown
549552

550-
[api-containerdirective]: #containerdirective
553+
[api-container-directive]: #containerdirective
551554

552555
[api-directive]: #directive
553556

554-
[api-leafdirective]: #leafdirective
557+
[api-leaf-directive]: #leafdirective
555558

556-
[api-textdirective]: #textdirective
559+
[api-text-directive]: #textdirective
557560

558561
[dfn-mxn-directive]: #directive-1

0 commit comments

Comments
 (0)