MVP #5.3 #75
|
@ -6,6 +6,11 @@
|
||||||
"name": "Erant",
|
"name": "Erant",
|
||||||
"orientation": "any",
|
"orientation": "any",
|
||||||
"scope": "/",
|
"scope": "/",
|
||||||
|
"serviceworker": {
|
||||||
|
"src": "service-worker.js",
|
||||||
|
"scope": "/",
|
||||||
|
"use_cache": false
|
||||||
|
},
|
||||||
"short_name": "erant",
|
"short_name": "erant",
|
||||||
"start_url": "/",
|
"start_url": "/",
|
||||||
"theme_color": "#ffffff",
|
"theme_color": "#ffffff",
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
// This is the service worker with the combined offline experience (Offline page + Offline copy of pages)
|
// This is the service worker with the combined offline experience (Offline page + Offline copy of pages)
|
||||||
|
import { workbox } from 'https://storage.googleapis.com/workbox-cdn/releases/5.1.4/workbox-sw.js'
|
||||||
|
|
||||||
const CACHE = 'pwabuilder-offline-page'
|
const CACHE = 'pwabuilder-offline-page'
|
||||||
|
|
||||||
importScripts('https://storage.googleapis.com/workbox-cdn/releases/5.1.4/workbox-sw.js')
|
importScripts('https://storage.googleapis.com/workbox-cdn/releases/5.1.4/workbox-sw.js')
|
||||||
|
|
||||||
// TODO: replace the following with the correct offline fallback page i.e.: const offlineFallbackPage = "offline.html";
|
// TODO: replace the following with the correct offline fallback page i.e.: const offlineFallbackPage = "offline.html";
|
||||||
const offlineFallbackPage = '/offline.html'
|
const offlineFallbackPage = '/offline.html'
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
"isolatedModules": true,
|
"isolatedModules": true,
|
||||||
"noEmit": true,
|
"noEmit": true,
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
|
"allowSyntheticDefaultImports": true,
|
||||||
"paths": {
|
"paths": {
|
||||||
"$lib/*": ["./src/lib/*"],
|
"$lib/*": ["./src/lib/*"],
|
||||||
"$root/*": ["./*"],
|
"$root/*": ["./*"],
|
||||||
|
|
|
@ -4,8 +4,11 @@ import preprocess from 'svelte-preprocess'
|
||||||
import path from 'path'
|
import path from 'path'
|
||||||
|
|
||||||
// https://vitejs.dev/config/
|
// https://vitejs.dev/config/
|
||||||
export default defineConfig({
|
/** @type {import('vite').UserConfig} */
|
||||||
|
export default {
|
||||||
|
// ...
|
||||||
resolve: {
|
resolve: {
|
||||||
|
|
||||||
alias: {
|
alias: {
|
||||||
$lib: path.resolve(__dirname, 'src', 'lib'),
|
$lib: path.resolve(__dirname, 'src', 'lib'),
|
||||||
$root: path.resolve(__dirname),
|
$root: path.resolve(__dirname),
|
||||||
|
@ -21,4 +24,4 @@ export default defineConfig({
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
]
|
]
|
||||||
})
|
}
|
Loading…
Reference in New Issue