MdastImportVisitor interface

Implement this interface to convert certian mdast nodes into lexical nodes.

Signature:

export interface MdastImportVisitor<UN extends Mdast.Content> 

Properties

PropertyModifiersTypeDescription
priority?number(Optional) Default 0, optional, sets the priority of the visitor. The higher the number, the earlier it will be called.
testNode((mdastNode: Mdast.Content | Mdast.Root) => boolean) | stringThe test function that determines if this visitor should be used for the given node. As a convenience, you can also pass a string here, which will be compared to the node's type.

Methods

MethodDescription
visitNode(params)The function that is called when the node is visited. See MdastVisitParams for details.