Created
September 10, 2020 12:15
-
-
Save mahdi-malv/7989beec31ae2fb501ef03be8d3feaa0 to your computer and use it in GitHub Desktop.
Web push snippet to add pushe to your website
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
<script src="https://static.pushe.co/pusheweb.js"></script> | |
<script> | |
Pushe.init("app_id"); // App_id is retrieved via console.pushe.co | |
Pushe.subscribe({"showDialog":true,"showBell":false,"icon":"https://static.pushe.co/d/webpush/default-icon.png","title":"Get the latest news bro :D","content":"You want to be notified of every new event happenning to My site? Click OK then.","position":"top-center","direction":"ltr","acceptText":"OK, sure","rejectText":"Nuh","promptTheme":"pushe-prompt-theme2","mobilePosition":"top","dialogRetryRate":0}); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment