node-webpush 1.0.5 → 1.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +3 -3
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -141,12 +141,12 @@ Constructing `WebPush` validates:
141
141
 
142
142
  ---
143
143
 
144
- ### `webpush.generateRequestDetails(subscription, payload?, options?)`
144
+ ### `webpush.generateRequest(subscription, payload?, options?)`
145
145
 
146
146
  Returns the request parameters to call `fetch()` yourself.
147
147
 
148
148
  ```ts
149
- const {endpoint, init} = webpush.generateRequestDetails(subscription, "payload", {
149
+ const {endpoint, init} = webpush.generateRequest(subscription, "payload", {
150
150
  TTL: 60,
151
151
  });
152
152
 
@@ -243,7 +243,7 @@ const webpush = new WebPush({
243
243
  },
244
244
  });
245
245
 
246
- const {endpoint, init} = webpush.generateRequestDetails(subscription, "ping", {
246
+ const {endpoint, init} = webpush.generateRequest(subscription, "ping", {
247
247
  TTL: 120,
248
248
  urgency: "high",
249
249
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-webpush",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "description": "A dependency-free Web Push implementation for Node.js",
5
5
  "main": "./dist/index.es.js",
6
6
  "module": "./dist/index.es.js",