Skip to content

Documentation


Documentation / @kizami/notify / WebPushChannelOptions

Interface: WebPushChannelOptions ​

Defined in: packages/notify/src/web-push.ts:52

Properties ​

defaultUrl? ​

optional defaultUrl?: string

Defined in: packages/notify/src/web-push.ts:56

通知クリック時に開く URL(サービスワーカーが使う)。省略時は "/"


fetchImpl? ​

optional fetchImpl?: (input, init?) => Promise<Response>

Defined in: packages/notify/src/web-push.ts:54

fetch の差し替え(テスト用)。省略時はグローバル fetch

MDN Reference

Parameters ​

input ​

URL | RequestInfo

init? ​

RequestInit

Returns ​

Promise<Response>


now? ​

optional now?: () => number

Defined in: packages/notify/src/web-push.ts:60

VAPID JWT の有効期限を決めるための現在時刻(ミリ秒)。テストで固定するための注入点

Returns ​

number


ttlSeconds? ​

optional ttlSeconds?: number

Defined in: packages/notify/src/web-push.ts:58

プッシュサービスに保持を依頼する秒数(既定 24 時間)。