Last active
October 22, 2017 23:42
-
-
Save beefchimi/d381556b7e17f96f3d6f16504d647899 to your computer and use it in GitHub Desktop.
Basic Single class implementation
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
import SoundFx from '../../SoundFx'; | |
export default function AnimationFeature() { | |
const target1 = document.getElementById('AnimationCube1'); | |
// ...more targets... | |
target1.addEventListener('mouseenter', () => { | |
SoundFx.Single.play('animationUp1'); | |
}); | |
// ...more mouseenter listeners... | |
target1.addEventListener('mousedown', () => { | |
SoundFx.Single.play('animationDown1'); | |
}); | |
// ...more mousedown listeners... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment