File tree 1 file changed +3
-3
lines changed 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 4
4
* @typedef {import('mdast-util-from-markdown').Extension } FromMarkdownExtension
5
5
* @typedef {import('mdast-util-from-markdown').Transform } FromMarkdownTransform
6
6
* @typedef {import('mdast-util-from-markdown').Handle } FromMarkdownHandle
7
+ * @typedef {import('mdast-util-to-markdown').ConstructName } ConstructName
7
8
* @typedef {import('mdast-util-to-markdown/lib/types.js').Options } ToMarkdownExtension
8
9
* @typedef {import('mdast-util-find-and-replace').ReplaceFunction } ReplaceFunction
9
10
* @typedef {import('mdast-util-find-and-replace').RegExpMatchObject } RegExpMatchObject
@@ -14,7 +15,9 @@ import {ccount} from 'ccount'
14
15
import { findAndReplace } from 'mdast-util-find-and-replace'
15
16
import { unicodePunctuation , unicodeWhitespace } from 'micromark-util-character'
16
17
18
+ /** @type {ConstructName } */
17
19
const inConstruct = 'phrasing'
20
+ /** @type {Array<ConstructName> } */
18
21
const notInConstruct = [ 'autolink' , 'link' , 'image' , 'label' ]
19
22
20
23
/** @type {FromMarkdownExtension } */
@@ -42,23 +45,20 @@ export const gfmAutolinkLiteralToMarkdown = {
42
45
before : '[+\\-.\\w]' ,
43
46
after : '[\\-.\\w]' ,
44
47
inConstruct,
45
- // @ts -expect-error: to do: use map.
46
48
notInConstruct
47
49
} ,
48
50
{
49
51
character : '.' ,
50
52
before : '[Ww]' ,
51
53
after : '[\\-.\\w]' ,
52
54
inConstruct,
53
- // @ts -expect-error: to do: use map.
54
55
notInConstruct
55
56
} ,
56
57
{
57
58
character : ':' ,
58
59
before : '[ps]' ,
59
60
after : '\\/' ,
60
61
inConstruct,
61
- // @ts -expect-error: to do: use map.
62
62
notInConstruct
63
63
}
64
64
]
You can’t perform that action at this time.
0 commit comments