Package Exports
- web-push
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (web-push) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
web-push
Web Push library for Node.js
encrypt(userPublicKey, payload)
Encrypts the payload according to the Message Encryption for Web Push standard.
- userPublicKey is the public key of the browser;
- payload is the message to attach to the notification.
sendNotification(endpoint, userPublicKey, payload)
Send a Push notification containing a message to an endpoint.
- endpoint is the endpoint URL;
- userPublicKey is the public key of the browser;
- payload is the message to attach to the notification.