isCData
import { isCData } from "jsr:@ende/xml";function
function isCData(node: XmlNode): node is XmlCDataNodeType guard to check if a node is a CDATA node.
node: XmlNodeThe XML node to check.
Returns
true if the node is a CDATA node, false otherwise.
Example: Usage
import { isCData } from "@ende/xml/types";
import { assertEquals } from "@ende/assert";
const node = { type: "cdata" as const, text: "<script>" };
assertEquals(isCData(node), true);