(node)
| 105 | // Callback hooks to add custom logic to nodes when visiting |
| 106 | // them. |
| 107 | onVisitLine(node) { |
| 108 | // Prevent lines from collapsing in `display: grid` mode, and |
| 109 | // allow empty lines to be copy/pasted |
| 110 | if (node.children.length === 0) { |
| 111 | node.children = [{ type: "text", value: " " }]; |
| 112 | } |
| 113 | }, |
| 114 | onVisitHighlightedLine(node) { |
| 115 | // Each line node by default has `class="line"`. |
| 116 | node.properties.className.push("highlighted"); |
nothing calls this directly
no outgoing calls
no test coverage detected