blob: 4b5b0c6fa840960a98ab1a7c851b4ebcb7eb7136 (
plain) (
tree)
|
|
import { defineConfig } from 'vite';
import { VitePWA } from 'vite-plugin-pwa';
// https://vitejs.dev/config/
export default defineConfig({
base: "/",
build: {
sourcemap: true,
assetsDir: "code",
},
plugins: [
VitePWA({
strategies: "injectManifest",
injectManifest: {
swSrc: 'public/sw.js',
swDest: 'dist/sw.js',
globDirectory: 'dist',
globPatterns: [
'**/*.{html,js,css,json, png}',
],
},
devOptions: {
enabled: true
}
})
]
})
|