NodeOptionsWithChildren

NodeOptionsWithChildren: NodeOptions & object

Type declaration

children

children: ElementContent[] | string

The HTML children of the node.

  • If a string, the string is added as raw HTML in the node.
  • If a object[], the object array is added as a hast node.

See

Examples

'<span class="icon">📝</span>'
[
  {
    type: "element",
    tagName: "span",
    properties: { className: ["icon"] },
    children: [
      {
        type: "text",
        value: "📝",
      },
    ],
  }
]

Defined in

packages/remark-callout/src/plugin.ts:210