CSS3 equivalent to jQuery slideUp and slideDown?

前端 未结 10 1102
没有蜡笔的小新
没有蜡笔的小新 2020-12-04 08:12

My application is performing poorly with jQuery\'s slideDown and slideUp. I\'m looking to use a CSS3 equivalent in browsers which support it.

Is it possible, using C

10条回答
  •  遥遥无期
    2020-12-04 08:59

    why not to take advantage of modern browsers css transition and make things simpler and fast using more css and less jquery

    Here is the code for sliding up and down

    Here is the code for sliding left to right

    Similarly we can change the sliding from top to bottom or right to left by changing transform-origin and transform: scaleX(0) or transform: scaleY(0) appropriately.

提交回复
热议问题