LoginSignup
33
31

More than 5 years have passed since last update.

CSSTransitionのイベントが終わった時に何かの処理をする

Last updated at Posted at 2014-07-29

備忘録的にメモです。

イベント完了のタイミングを知る方法

$("検知したいターゲット").bind("oTransitionEnd mozTransitionEnd webkitTransitionEnd transitionend", function(){
    alert("TransitionEnd");
});

基本的にはtransitionendで検知できるらしいです。
古いバージョンでも検知したいので、oTransitionEnd mozTransitionEnd webkitTransitionEndを追加しています。

これで大体のブラウザに対応できると思います。

33
31
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
33
31