File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 44 * @typedef {import('mdast-util-from-markdown').Extension } FromMarkdownExtension
55 * @typedef {import('mdast-util-from-markdown').Transform } FromMarkdownTransform
66 * @typedef {import('mdast-util-from-markdown').Handle } FromMarkdownHandle
7+ * @typedef {import('mdast-util-to-markdown').ConstructName } ConstructName
78 * @typedef {import('mdast-util-to-markdown/lib/types.js').Options } ToMarkdownExtension
89 * @typedef {import('mdast-util-find-and-replace').ReplaceFunction } ReplaceFunction
910 * @typedef {import('mdast-util-find-and-replace').RegExpMatchObject } RegExpMatchObject
@@ -14,7 +15,9 @@ import {ccount} from 'ccount'
1415import { findAndReplace } from 'mdast-util-find-and-replace'
1516import { unicodePunctuation , unicodeWhitespace } from 'micromark-util-character'
1617
18+ /** @type {ConstructName } */
1719const inConstruct = 'phrasing'
20+ /** @type {Array<ConstructName> } */
1821const notInConstruct = [ 'autolink' , 'link' , 'image' , 'label' ]
1922
2023/** @type {FromMarkdownExtension } */
@@ -42,23 +45,20 @@ export const gfmAutolinkLiteralToMarkdown = {
4245 before : '[+\\-.\\w]' ,
4346 after : '[\\-.\\w]' ,
4447 inConstruct,
45- // @ts -expect-error: to do: use map.
4648 notInConstruct
4749 } ,
4850 {
4951 character : '.' ,
5052 before : '[Ww]' ,
5153 after : '[\\-.\\w]' ,
5254 inConstruct,
53- // @ts -expect-error: to do: use map.
5455 notInConstruct
5556 } ,
5657 {
5758 character : ':' ,
5859 before : '[ps]' ,
5960 after : '\\/' ,
6061 inConstruct,
61- // @ts -expect-error: to do: use map.
6262 notInConstruct
6363 }
6464 ]
You can’t perform that action at this time.
0 commit comments