English
DevOptions
Development options.
Properties
| Property | Type | Default | Description |
|---|---|---|---|
disableRuntimeConfig? | boolean | false | This option will enable you to not use the runtimeConfig configured on workbox.runtimeConfig plugin option.WARNING: this option will only be used when using generateSW strategy. |
enabled? | boolean | false | Should the service worker be available on development?. |
enableUISwitcher? | boolean | true | When using dual service worker build, enable UI switcher? |
inspector? | "standalone" | "vite-devtools" | undefined | Enable Vite PWA inspector? |
navigateFallback? | string | 'index.html' | This option will allow you to configure the navigateFallback when using registerRoute for offline support: configure here the corresponding url, for example navigateFallback: 'index.html'.WARNING: this option will only be used when using injectManifest/buildSW strategies. |
navigateFallbackAllowlist? | RegExp[] | [/^/$/] | This option will allow you to configure the navigateFallbackAllowlist: new option from version v0.12.4.Since we need at least the entry point in the service worker's precache manifest, we don't want the rest of the assets to be intercepted by the service worker. If you configure this option, the plugin will use it instead the default. WARNING: this option will only be used when using generateSW strategy. |
resolveTempFolder? | () => string | Promise<string> | resolve(viteConfig.root, 'node_modules/.pwa-dev-dist') | Where to store generated service worker in development when using generateSW strategy.Use it with caution, it should be used only by framework integrations. |
suppressWarnings? | boolean | true | Suppress workbox-build warnings?. WARNING: this option will only be used when using generateSW/injectManifest/buildSW strategy. If enabled, globPatterns will be changed to [*.js] and a new empty suppress-warnings.js file will be created in dev-dist folder. |
type? | WorkerType | 'classic' | The service worker type. |