Created
October 28, 2019 14:43
-
-
Save thepassle/6c008329a57bb3a84bc88415973074a9 to your computer and use it in GitHub Desktop.
installing7
This file contains hidden or 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
button.addEventListener('click', async () => { | |
deferredPrompt.prompt(); | |
const { outcome } = await deferredPrompt.userChoice; | |
if (outcome === 'accepted') button.setAttribute('hidden', '); | |
// Send an analytics event for either dismissed or accepted! | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment