ProcessingInstruction
Hierarchy
- DataNode
- ProcessingInstruction
Index
Constructors
constructor
Parameters
name: string
data: string
Returns ProcessingInstruction
Properties
children
publicdata
The content of the data node
endIndex
The end index of the node. Requires withEndIndices
on the handler to be `true.
publicname
next
Next sibling
parent
Parent of the node
prev
Previous sibling
startIndex
The start index of the node. Requires withStartIndices
on the handler to be `true.
type
The type of the node.
optionalx-name
If this is a doctype, the document type name (parse5 only).
optionalx-publicId
If this is a doctype, the document type public identifier (parse5 only).
optionalx-systemId
If this is a doctype, the document type system identifier (parse5 only).
Accessors
loc
nextSibling
nodeType
DOM spec-compatible node type.
Returns 1
nodeValue
Same as data. DOM spec-compatible alias.
Returns string
Parameters
data: string
Returns void
parentNode
Same as parent. DOM spec-compatible alias.
Returns null | ParentNode
Parameters
parent: null | ParentNode
Returns void
previousSibling
Methods
cloneNode
Clone this node, and optionally its children.
Type parameters
- T: Node
Parameters
this: T
recursive: boolean = false
Clone child nodes as well.
Returns T
A clone of the node.
Processing instructions, including doc types.