DEV Community

Discussion on: Create a parallax effect when the mouse moves

Collapse
 
clementgaudiniere profile image
Clément Gaudinière

I did not know, indeed it is better.

Collapse
 
cheestudio profile image
Lars Faye

You're both incredible! This was so applicable to what I needed to do!

Both methods have merit, and your original approach I think is more understandable in a way, but Luke's method does make sense from a performance perspective, and that we're relegating the languages to their proper jobs (JS for DOM interactive, CSS for element presentation/animation).

Thank you both! 🙌🏻