@braze/service-worker

5.8.1 • Public • Published

Install

$ npm install --save @braze/web-sdk
$ npm install --save @braze/service-worker

This will install the Braze Service Worker files into ./node_modules/@braze/service-worker where you can reference them locally. Note that the Braze Service Worker is only meant to be used along with the Braze Web SDK.

Usage

In your build process, copy node_modules/@braze/service-worker/service-worker.js to your web application's public root directory.

Then, using the Web SDK, provide the serviceWorkerLocation initialization option with the path to your service worker.

See our documentation pages for steps to integrate push notifications into your website using the Braze Web SDK.

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i @braze/service-worker

      Weekly Downloads

      10,601

      Version

      5.8.1

      License

      SEE LICENSE IN https://github.com/braze-inc/braze-web-sdk/blob/master/LICENSE

      Unpacked Size

      25.2 kB

      Total Files

      3

      Last publish

      Collaborators

      • appboy