This repo is now deprecated, check @vite-pwa/sveltekit (wip).
Updated PWA Plugin with vite-pwa/vite-plugin-pwa#371 local copy.
Added logic that will go to the SvelteKit integration: check Vite config file.
The logic in configureOptions
function will be provided by the new SvelteKit integration in Vite Plugin PWA.
Updated PWA Plugin with vite-pwa/vite-plugin-pwa#370 local copy (we need to fix types).
Added logic that will go to the SvelteKit integration: check Vite config file.
WARNING: SvelteKit not updated, failing post install script when installing latest version (474).
WARNING: current version failing on build running the adapter, I need to fix it.
UPDATED to Vite 3.1.0-beta1 and latest SvelteKit 1.0.0-next.454:
- hacking
VitePluginPWA
to configure the newRollup
sequential hook incloseBundle
: check thevite.config.js
module (DON'T DO THIS, we're preparing a new version to support Vite 3.1) - migrated project with
pnpm dlx svelte-migrate routes
- requires
node 16.14+
: tested withnode 16.17.0 LTS
.
WARNING - DON'T USE THIS: we're awating Rollup and Vite to add sequential parallel hooks support:
- RFC: https://github.com/vitejs/vite/discussions/9442
- Rollup PR (Lukas Taegert-Atkinson and Anthony Fu): rollup/rollup#4600
- Vite PR (Anthony Fu): vitejs/vite#9634
Finally!, it works.
Using a local build of the PWA PR: vite-pwa/vite-plugin-pwa#327.
If you had a previous version, just remove the node_modules
and run pnpm install
.
To test it just run:
pnpm run build && pnpm run preview
orpnpm run build && pnpm run https
to test with https