Last active
December 5, 2018 07:52
-
-
Save tamara-dietz/6b55091458d73f4fbf06f8fc4fc4020f to your computer and use it in GitHub Desktop.
Parallax
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="scene" class="float-right"> | |
<div data-depth="1.00"><img src="img/parallax/layer2.png"></div> | |
</div> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/parallax/3.1.0/parallax.min.js"></script> | |
<script> | |
// Pretty simple huh? | |
var scene = document.getElementById('scene'); | |
new Parallax(scene,{ | |
relativeInput: true | |
}); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment