Skip to content

Set-up guide of firebase with custom-service- worker.js using 'InjectManifest' mode #9065

Discussion options

You must be logged in to vote

in quasar.conf.js file

pwa: {
      workboxPluginMode: 'InjectManifest',
      workboxOptions: {
        // skipWaiting: true,
        // clientsClaim: true
      },
}

your 'register-service-worker.js' file

/*
 * This file is picked up by the build system only
 * when building for PRODUCTION
 */

import { register } from 'register-service-worker'
import { Notify } from 'quasar'

let swReg = null
register(process.env.SERVICE_WORKER_FILE, {
  ready(registration) {
    swReg = registration
    console.log('App is being served from cache by a service worker.')
  },
  registered(registration) { // registration -> a ServiceWorkerRegistration instance
    console.log('Service worker has been re…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@jitendra1607
Comment options

Answer selected by jitendra1607
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant