SVGElement: load event
The load
event fires on an SVGElement
when it is loaded in the browser, e.g. in the DOM in the case of an embedded <svg>
. It is basically the same as the standard load
DOM event.
Examples
svgElem.addEventListener('load', () => { console.log('SVG loaded.'); })
Specifications
Browser compatibility
Desktop | Mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | WebView Android | Chrome Android | Firefox for Android | Opera Android | Safari on IOS | Samsung Internet | |
load_event |
1 |
12 |
4
See bug 620002 for implementation status of the standard
load event. |
9 |
≤12.1 |
3 |
≤37 |
18 |
4
See bug 620002 for implementation status of the standard
load event. |
≤12.1 |
1 |
1.0 |
© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/SVGElement/load_event