HTMLObjectElement: getSVGDocument() method

فهرست فصل‌ها دانلود آرشیوناشر

MDN Web Docs · نسخهٔ df622a2a1c1e · CC BY-SA 2.5 و مجوز جداگانهٔ ناشر برای نمونه‌کد

{{APIRef("HTML DOM")}}

The **getSVGDocument()** method of the {{domxref("HTMLObjectElement")}} interface returns the {{domxref("Document")}} object of the embedded SVG.

Syntax

js-nolint
getSVGDocument()

Parameters

None.

Return value

A {{domxref("Document")}}.

Examples

js
const svg = document.getElementById("el").getSVGDocument();

Specifications

{{Specifications}}

Browser compatibility

{{Compat}}

See also

  • {{domxref("HTMLIFrameElement.getSVGDocument")}}
  • {{domxref("HTMLEmbedElement.getSVGDocument")}}