Document: rootElement property - Web APIs | MDN

Value

For SVG elements, the Element that is the root element of the document; otherwise null.

If the document is a non-empty SVG document, then the rootElement will be an SVGSVGElement, identical to the documentElement.

Specifications

Specification
Scalable Vector Graphics (SVG) 2
# __svg__SVGDocument__rootElement

Browser compatibility

Help improve MDN

Learn how to contribute

This page was last modified on by MDN contributors.