xmldom

Frameworks & Libraries

A pure-JavaScript W3C standard DOM parser and serializer for XML.

Latest 0.9.11 · by xmldomWebsitexmldom/xmldom

Branches

0.9
0.9.11
0.8
0.8.14

Release activity

Release activity — 7 releases across 4 days in the last year. Each cell is one day; darker means more releases that day. Older weeks are hidden at this screen width.
MayJunJulAug
SundayNo releases on May 3, 2026No releases on May 10, 2026No releases on May 17, 2026No releases on May 24, 2026No releases on May 31, 2026No releases on Jun 7, 2026No releases on Jun 14, 2026No releases on Jun 21, 2026No releases on Jun 28, 2026No releases on Jul 5, 2026No releases on Jul 12, 2026No releases on Jul 19, 2026No releases on Jul 26, 2026No releases on Aug 2, 2026No releases on Aug 9, 2026No releases on Aug 16, 2026
MondayNo releases on May 4, 2026No releases on May 11, 2026No releases on May 18, 2026No releases on May 25, 2026No releases on Jun 1, 2026No releases on Jun 8, 2026No releases on Jun 15, 2026No releases on Jun 22, 2026No releases on Jun 29, 2026No releases on Jul 6, 2026No releases on Jul 13, 2026No releases on Jul 20, 2026No releases on Jul 27, 2026No releases on Aug 3, 2026No releases on Aug 10, 2026No releases on Aug 17, 2026
TuesdayNo releases on May 5, 2026No releases on May 12, 2026No releases on May 19, 2026No releases on May 26, 2026No releases on Jun 2, 2026No releases on Jun 9, 2026No releases on Jun 16, 2026No releases on Jun 23, 2026No releases on Jun 30, 2026No releases on Jul 7, 2026No releases on Jul 14, 2026No releases on Jul 21, 2026No releases on Jul 28, 2026No releases on Aug 4, 2026No releases on Aug 11, 2026No releases on Aug 18, 2026
WednesdayNo releases on May 6, 2026No releases on May 13, 2026No releases on May 20, 2026No releases on May 27, 2026No releases on Jun 3, 2026No releases on Jun 10, 2026No releases on Jun 17, 2026No releases on Jun 24, 2026No releases on Jul 1, 2026No releases on Jul 8, 2026No releases on Jul 15, 2026No releases on Jul 22, 2026No releases on Jul 29, 2026No releases on Aug 5, 20262 releases on Aug 12, 2026No releases on Aug 19, 2026
ThursdayNo releases on May 7, 2026No releases on May 14, 2026No releases on May 21, 2026No releases on May 28, 2026No releases on Jun 4, 2026No releases on Jun 11, 2026No releases on Jun 18, 2026No releases on Jun 25, 2026No releases on Jul 2, 2026No releases on Jul 9, 2026No releases on Jul 16, 2026No releases on Jul 23, 2026No releases on Jul 30, 2026No releases on Aug 6, 2026No releases on Aug 13, 2026
FridayNo releases on May 8, 2026No releases on May 15, 2026No releases on May 22, 2026No releases on May 29, 2026No releases on Jun 5, 2026No releases on Jun 12, 2026No releases on Jun 19, 2026No releases on Jun 26, 2026No releases on Jul 3, 2026No releases on Jul 10, 2026No releases on Jul 17, 2026No releases on Jul 24, 2026No releases on Jul 31, 2026No releases on Aug 7, 2026No releases on Aug 14, 2026
SaturdayNo releases on May 9, 2026No releases on May 16, 2026No releases on May 23, 2026No releases on May 30, 2026No releases on Jun 6, 2026No releases on Jun 13, 2026No releases on Jun 20, 2026No releases on Jun 27, 2026No releases on Jul 4, 2026No releases on Jul 11, 2026No releases on Jul 18, 2026No releases on Jul 25, 2026No releases on Aug 1, 2026No releases on Aug 8, 2026No releases on Aug 15, 2026

7 releases in the last year, busiest day 2

Changelog

Filter releases by branch
10 of 10 releases

0.9.11

Latest
Fixed 1
  • CharacterData nodeValue and data are now kept in sync
Security 2
  • XMLSerializer.serializeToString() now rejects invalid element and attribute names when requireWellFormed is true, throwing InvalidStateError for names that are not valid XML QNames, preventing XML injection via createElement() and setAttribute()
  • Processing-instruction grammar regex no longer backtracks quadratically on unterminated processing instructions, preventing denial-of-service attacks reachable from DOMParser.parseFromString()

From xmldom

Commits

Fixed
  • Security: XMLSerializer.serializeToString() now also rejects invalid element and attribute names when { requireWellFormed: true } is passed, throwing InvalidStateError for a name that is not a valid XML QName (this covers the namespace prefix, which surfaces in the element qualified name or in a synthesized xmlns: declaration). This prevents XML injection via createElement() / setAttribute(), extending the existing requireWellFormed checks to the serialized name set. GHSA-w2rr-34g9-rvrj GHSA-4w3w-2rp5-g8jm
  • Security: the processing-instruction grammar regex no longer backtracks quadratically on an unterminated processing instruction (<?… with no closing ?>), preventing a denial-of-service (ReDoS) reachable from DOMParser.parseFromString with default options. GHSA-g53g-w8rj-fmg7
  • CharacterData nodeValue and data are now kept in sync #990
Chore
  • updated dependencies

Thank you, @bhaswanthc, @jmestwa-coder, @stevenobiajulu, for your contributions

View originalPermalink
How 0.9.11 went

0.8.14

Security 1
  • XMLSerializer.serializeToString() now rejects invalid element and attribute names when requireWellFormed: true is passed, throwing InvalidStateError for names that are not valid XML QNames, preventing XML injection via createElement() and setAttribute()

From xmldom

Commits

Fixed
  • Security: XMLSerializer.serializeToString() now also rejects invalid element and attribute names when { requireWellFormed: true } is passed, throwing InvalidStateError for a name that is not a valid XML QName (this covers the namespace prefix, which surfaces in the element qualified name or in a synthesized xmlns: declaration). This prevents XML injection via createElement() / setAttribute(), extending the existing requireWellFormed checks to the serialized name set. GHSA-w2rr-34g9-rvrj GHSA-4w3w-2rp5-g8jm

Thank you, @bhaswanthc, @jmestwa-coder, for your contributions

View originalPermalink
How 0.8.14 went

0.9.10

Fixed 1
  • isEqualNode now correctly returns false for CDATASection nodes with different data
Deprecated 1
  • The splitCDATASections serializer option is deprecated and will be removed in the next breaking release
Security 2
  • XMLSerializer.serializeToString() (and Node.toString(), NodeList.toString()) now accept a requireWellFormed option that throws InvalidStateError for injection-prone node content when enabled
  • DOM traversal operations (XMLSerializer.serializeToString(), Node.prototype.normalize(), Node.prototype.cloneNode(true), Document.prototype.importNode(node, true), node.textContent getter, getElementsByTagName() / getElementsByTagNameNS() / getElementsByClassName() / getElementById(), Node.prototype.isEqualNode()) are now iterative to prevent stack exhaustion on deeply nested DOM trees

From xmldom

Commits

Fixed
  • Security: XMLSerializer.serializeToString() (and Node.toString(), NodeList.toString()) now accept a requireWellFormed option. When { requireWellFormed: true } is passed, the serializer throws InvalidStateError for injection-prone node content, preventing XML injection via attacker-controlled node data. GHSA-j759-j44w-7fr8 GHSA-x6wf-f3px-wcqx GHSA-f6ww-3ggp-fr8h
    • Comment: throws when data contains -- anywhere, ends with -, or contains characters outside the XML Char production
    • ProcessingInstruction: throws when target contains : or matches xml (case-insensitive), or data contains characters outside the XML Char production or contains ?>
    • DocumentType: throws when publicId fails PubidLiteral, systemId fails SystemLiteral, or internalSubset contains ]>
  • Security: DOM traversal operations (XMLSerializer.serializeToString(), Node.prototype.normalize(), Node.prototype.cloneNode(true), Document.prototype.importNode(node, true), node.textContent getter, getElementsByTagName() / getElementsByTagNameNS() / getElementsByClassName() / getElementById(), Node.prototype.isEqualNode()) are now iterative. Previously, deeply nested DOM trees would exhaust the JavaScript call stack and throw an unrecoverable RangeError. GHSA-2v35-w6hq-6mfw
  • isEqualNode now correctly returns false for CDATASection nodes with different data
Deprecated
  • The splitCDATASections serializer option is deprecated and will be removed in the next breaking release. The automatic splitting of "]]>" in CDATASection data was introduced as a workaround; use requireWellFormed: true or ensure CDATASection data does not contain "]]>" before serialization.
Chore
  • updated dependencies

Thank you, @Jvr2022, @praveen-kv, @TharVid, @decsecre583, @tlsbollei, @KarimTantawey, for your contributions

View originalPermalink
How 0.9.10 went

0.8.13

Security 2
  • XMLSerializer.serializeToString() (and Node.toString(), NodeList.toString()) now accept a requireWellFormed option that throws InvalidStateError for injection-prone node content when enabled, preventing XML injection via attacker-controlled node data
  • DOM traversal operations (XMLSerializer.serializeToString(), Node.prototype.normalize(), Node.prototype.cloneNode(true), Document.prototype.importNode(node, true), node.textContent getter, getElementsByTagName() / getElementsByTagNameNS() / getElementsByClassName() / getElementById()) are now iterative to prevent stack exhaustion on deeply nested DOM trees

From xmldom

Commits

Fixed
  • Security: XMLSerializer.serializeToString() (and Node.toString(), NodeList.toString()) now accept a requireWellFormed option (fourth argument, after isHtml and nodeFilter). When { requireWellFormed: true } is passed, the serializer throws InvalidStateError for injection-prone node content, preventing XML injection via attacker-controlled node data. GHSA-j759-j44w-7fr8 GHSA-x6wf-f3px-wcqx GHSA-f6ww-3ggp-fr8h
    • Comment: throws when data contains -->
    • ProcessingInstruction: throws when data contains ?>
    • DocumentType: throws when publicId fails PubidLiteral, systemId fails SystemLiteral, or internalSubset contains ]>
  • Security: DOM traversal operations (XMLSerializer.serializeToString(), Node.prototype.normalize(), Node.prototype.cloneNode(true), Document.prototype.importNode(node, true), node.textContent getter, getElementsByTagName() / getElementsByTagNameNS() / getElementsByClassName() / getElementById()) are now iterative. Previously, deeply nested DOM trees would exhaust the JavaScript call stack and throw an unrecoverable RangeError. GHSA-2v35-w6hq-6mfw

Thank you, @Jvr2022, @praveen-kv, @TharVid, @decsecre583, @tlsbollei, @KarimTantawey, for your contributions

View originalPermalink
How 0.8.13 went

0.9.9

Added 1
  • Implement ParentNode.children getter
Fixed 1
  • Correctly traverse ancestor chain in Node.contains
Security 2
  • createCDATASection now throws InvalidCharacterError when data contains "]]>", as required by the WHATWG DOM spec
  • XMLSerializer now splits CDATASection nodes whose data contains "]]>" into adjacent CDATA sections at serialization time, preventing XML injection via mutation methods

From xmldom

Commits

Added
  • implement ParentNode.children getter #960 / #410
Fixed
  • Security: createCDATASection now throws InvalidCharacterError when data contains "]]>", as required by the WHATWG DOM spec. GHSA-wh4c-j3r5-mjhp
  • Security: XMLSerializer now splits CDATASection nodes whose data contains "]]>" into adjacent CDATA sections at serialization time, preventing XML injection via mutation methods (appendData, replaceData, .data =, .textContent =). GHSA-wh4c-j3r5-mjhp
  • correctly traverse ancestor chain in Node.contains #931

Code that passes a string containing "]]>" to createCDATASection and relied on the previously unsafe behavior will now receive InvalidCharacterError. Use a mutation method such as appendData if you intentionally need "]]>" in a CDATASection node's data.

Chore
  • updated dependencies

Thank you, @stevenobiajulu, @yoshi389111, @thesmartshadow, for your contributions

https://github.com/xmldom/xmldom/discussions/435

View originalPermalink
How 0.9.9 went

0.8.12

Fixed 1
  • Preserve trailing whitespace in ProcessingInstruction data
Security 2
  • createCDATASection now throws InvalidCharacterError when data contains "]]>", as required by the WHATWG DOM spec
  • XMLSerializer now splits CDATASection nodes whose data contains "]]>" into adjacent CDATA sections at serialization time, preventing XML injection via mutation methods

From xmldom

Commits

Fixed
  • preserve trailing whitespace in ProcessingInstruction data #962 / #42
  • Security: createCDATASection now throws InvalidCharacterError when data contains "]]>", as required by the WHATWG DOM spec. GHSA-wh4c-j3r5-mjhp
  • Security: XMLSerializer now splits CDATASection nodes whose data contains "]]>" into adjacent CDATA sections at serialization time, preventing XML injection via mutation methods (appendData, replaceData, .data =, .textContent =). GHSA-wh4c-j3r5-mjhp

Code that passes a string containing "]]>" to createCDATASection and relied on the previously unsafe behavior will now receive InvalidCharacterError. Use a mutation method such as appendData if you intentionally need "]]>" in a CDATASection node's data.

Thank you, @thesmartshadow, @stevenobiajulu, for your contributions

https://github.com/xmldom/xmldom/discussions/357

View originalPermalink
How 0.8.12 went

0.8.11

Fixed 1
  • update ownerDocument when moving nodes between documents

From xmldom

Fixed
  • update ownerDocument when moving nodes between documents #933 / #932

Thank you, @shunkica, for your contributions

View originalPermalink
How 0.8.11 went

0.9.8

Changed 1
  • speed up line detection
Fixed 1
  • replace \u2029 as part of normalizeLineEndings

From xmldom

Commits

Fixed
  • fix: replace \u2029 as part of normalizeLineEndings #839 / #838
  • perf: speed up line detection #847 / #838
Chore
  • updated dependencies
  • drop jazzer and rxjs devDependencies #845

Thank you, @kboshold, @Ponynjaa, for your contributions.

https://github.com/xmldom/xmldom/discussions/435

View originalPermalink
How 0.9.8 went

0.9.7

Added 1
  • Implementation of hasAttributes
Changed 1
  • simplify DOM.compareDocumentPosition
Fixed 2
  • locator is now true even when other options are being used for the DOMParser
  • allow case-insensitive DOCTYPE in HTML

From xmldom

Commits

Added
  • Implementation of hasAttributes #804
Fixed
  • locator is now true even when other options are being used for the DOMParser #802 / #803
  • allow case-insensitive DOCTYPE in HTML #817 / #819
Performance
  • simplify DOM.compareDocumentPosition #805
Chore
  • updated devDependencies

Thank you, @zorkow, @Ponynjaa, @WesselKroos, for your contributions.

https://github.com/xmldom/xmldom/discussions/435

View originalPermalink
How 0.9.7 went

0.9.6

Fixed 1
  • Lower error level for unicode replacement character

From xmldom

Commits
Fixed
  • lower error level for unicode replacement character #790 / #794 / #797
Chore
  • updated devDependencies
  • migrate renovate config #792

Thank you, @eglitise, for your contributions.

View originalPermalink
How 0.9.6 went
View all

Discussion

If you publish xmldom, you can claim this product by proving you administer its repository.