Skip to content

Commit

Permalink
custome push notification +1
Browse files Browse the repository at this point in the history
  • Loading branch information
appsaeed committed Mar 15, 2024
1 parent 048d722 commit f8b7f2a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/MainProvider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,10 @@ export default function MainProvider({ children }: { children: ReactNode }) {
applicationServerKey: urlBase64ToUint8Array('BNt0ygqWTSXEd9AJ_Vv2e0jaK73vAjCykOD58lXwinRrnkpwX0lN1cGETwjS10Tvby3d9fDSNZMy6ZdA4xmA30U')
}).then(subscription => {

//create token to base64 encode
const token = btoa(JSON.stringify(subscription));

//save to local storage
localStorage.setItem('notify_token', token)

})
Expand Down

0 comments on commit f8b7f2a

Please sign in to comment.