Simple & lightweight (<4kb gzipped) vanilla JavaScript library to create smooth & beautiful animations when you scroll.
:
instead of -
so that negative values cam be used. For example lax_preset_spin-400-360
should now be written as lax_preset_spin:400:360
document.body.scrollTop
and document.body.scrollLeft
with window.scrollY
and window.scrollX
in example and documentationLax.js 2.0 has been completely re-written with a focus on modularity and flexibility giving you more tools to create awesome animations.
Added rotateX and rotateY transforms
Fixed a problem with lax.addElement fixing #36
lax
class to any element you want to animate.data-lax-optimize
to data-lax-use-gpu
data-lax-optimize
for optimising elements off screen