Initial checklist
Affected package
[email protected]
Steps to reproduce
Like syntax-tree/unist-util-visit-parents#17
import { Root } from 'mdast'
import { visit } from 'unist-util-visit'
export default function plugin() {
return function (tree: Root) {
visit(tree, ['link', 'linkReference'] as const, node => {
console.log(node)
// ^?
});
};
}
TypeScript Playground
Actual behavior
Expected behavior
node should be Link | LinkReference
Runtime
No response
Package manager
No response
Operating system
No response
Build and bundle tools
No response
Initial checklist
Affected package
[email protected]
Steps to reproduce
Like syntax-tree/unist-util-visit-parents#17
TypeScript Playground
Actual behavior
Expected behavior
nodeshould beLink | LinkReferenceRuntime
No response
Package manager
No response
Operating system
No response
Build and bundle tools
No response