Skip to content

Commit

Permalink
feat: add one signal
Browse files Browse the repository at this point in the history
  • Loading branch information
jesusantguerrero committed Oct 23, 2024
1 parent fc1b166 commit 92c4f83
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
1 change: 1 addition & 0 deletions public/OneSignalSDKWorker.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
importScripts("https://cdn.onesignal.com/sdks/web/v16/OneSignalSDK.sw.js");
13 changes: 13 additions & 0 deletions resources/views/app.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,19 @@
@routes
@vite('resources/js/app.js')
@inertiaHead
<script src="https://cdn.onesignal.com/sdks/web/v16/OneSignalSDK.page.js" defer></script>
<script>
window.OneSignalDeferred = window.OneSignalDeferred || [];
OneSignalDeferred.push(async function(OneSignal) {
await OneSignal.init({
appId: "2079c6fb-f627-4132-893d-55a9df3d466d",
safari_web_id: "web.onesignal.auto.3f550615-46c0-4fa5-9ee8-42953ece3d19",
notifyButton: {
enable: true,
},
});
});
</script>
</head>
<body class="font-sans antialiased">
@inertia
Expand Down

0 comments on commit 92c4f83

Please sign in to comment.