Closed pwFoo closed 6 years ago
Hello @pwFoo,
It's fairly simple, the input just needs to match the Subscription
struct: https://github.com/SherClockHolmes/webpush-go/blob/master/webpush.go#L73
Which is modeled after: pushManager.getSubscription()
. You can grab the subscription using: https://developer.mozilla.org/en-US/docs/Web/API/PushManager/getSubscription, and then send the subscription to your server.
Hi @SherClockHolmes ,
is there a simple demo available with client side javascript code? I have js code optimized for web-push-php, but there a some differences (post content handling).