MdastImportVisitor interface
Implement this interface to convert certian mdast nodes into lexical nodes.
Signature:
export interface MdastImportVisitor<UN extends Mdast.Content>
Properties
Property | Modifiers | Type | Description |
---|---|---|---|
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) | string | The 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
Method | Description |
---|---|
visitNode(params) | The function that is called when the node is visited. See MdastVisitParams for details. |