The AnimationPlaybackEvent()
constructor of the Web Animations API returns a new AnimationPlaybackEvent
object instance.
On this page
AnimationPlaybackEvent: AnimationPlaybackEvent() constructor
Syntax
js
new AnimationPlaybackEvent(type)
new AnimationPlaybackEvent(type, options)
Parameters
-
type
-
A string with the name of the event. It is case-sensitive and browsers set it to
cancel
,finish
, orremove
. options
Optional-
An object that, in addition of the properties defined in
Event()
, has the following properties:detail
Optional-
An event-dependent value associated with the event. Defaults to
null
.
Return value
A new AnimationPlaybackEvent
object.
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 | |
AnimationPlaybackEvent |
84 | 84 | 63 | No | 70 | 13.1 | 84 | 84 | 63 | 60 | 13.4 | 14.0 |
See also
© 2005–2023 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/AnimationPlaybackEvent/AnimationPlaybackEvent