The SVGAnimationElement.targetElement
property refers to the element which is being animated. If no target element is being animated (for example, because the href
attribute specifies an unknown element), the value returned is null
.
var targetElement = someElement.targetElement;
Specification | Status | Comment |
SVG Animations Level 2 The definition of 'SVGAnimationElement.targetElement' in that specification. | Editor's Draft | Added null as return value in case that no target element is being animated. |
Scalable Vector Graphics (SVG) 1.1 (Second Edition) The definition of 'SVGAnimationElement.targetElement' in that specification. | Recommendation | Initial definition |
Desktop | ||||||
---|---|---|---|---|---|---|
Chrome | Edge | Firefox | Internet Explorer | Opera | Safari | |
Basic support | Yes | No | Yes | No | Yes | Yes |
Mobile | |||||||
---|---|---|---|---|---|---|---|
Android webview | Chrome for Android | Edge Mobile | Firefox for Android | Opera for Android | iOS Safari | Samsung Internet | |
Basic support | ? | ? | No | ? | ? | ? | ? |
© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/SVGAnimationElement/targetElement