JQuery easing vs CSS3 transition - is there any exact anti-aliasing?

I use jQuery for animation along with CSS3 transition.

The problem is that I could not find the equivalent smoothing animation. Whether there is a?

The closest I got this (jQuery easeOutQuad and CSS3 by default).

CSS

#div1 { transition: width 0.5s; } 

JQuery

 $('#div2').animate({'width': 200}, 500, 'easeOutQuad'); 

http://jsfiddle.net/bzw4q/

But they are still different.

I want both to revive at the same time (using any good attenuation algorithm). Is it possible?

+6
source share
2 answers

Try it with swing and ease-in-out > http://jsfiddle.net/et6Hg/

I think you have better chances :)

+2
source

Also here http://easings.net to get the corresponding cubic bezier.

0
source

Source: https://habr.com/ru/post/948997/


All Articles