Send web push notification with ease and zero cost on scale.
Prerequisites
Taak SDK JS
We use Taak SDK JS as client side library. Full source code is available at here
Check permission
Following code is for React library, but basically must work in both TypeScript and JavaScript projects.
Check if permission given
WebPushToggle.tsx
Subscribe
Check if subscribed
WebPushSubscribeButton.tsx
Subscribe
WebPushSubscribeButton.tsx
Send
Send web push
WebPushSubscriptionList.tsx
List
Subscription list
WebPushSubscriptionList.tsx
Delete
Delete an subscription
WebPushSubscriptionList.tsx
Test suite
index.test.ts