AnimationEvent: elapsedTime プロパティ

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since September 2015.

We'd love to hear more about your role and the company you work for
Please help us by answering a few questions.

AnimationEvent.elapsedTime は読み取り専用のプロパティで、アニメーションが開始されてからの秒数を float 型で表します。このイベントが発生したとき、アニメーションが停止した場合を除いて常に設定されます。 animationstart イベントにおいては elapsedTime0.0 になりますが、 animation-delay が負の値の場合は、このイベントは elapsedTime(-1 * 待ち時間 ) であるときに発生します。

float 型で、時間の量を秒単位で指定します。

仕様書

Specification
CSS Animations Level 1
# dom-animationevent-elapsedtime

ブラウザーの互換性

関連情報