Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: move client to @vite-pwa/workbox-window #634

Draft
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

userquin
Copy link
Member

@userquin userquin commented Dec 31, 2023

This PR also includes installing event support for VanillaJS and all frameworks:

  • VanillaJS: onInstalling and onUpdateFound callbacks
  • Frameworks: same callbacks for VanillaJS and reactive installingSW and updatingSW props

I need to review if installingSW and updatingSW can be read only (when exposing them), the logic should be handled internally, installing event is a transient event.

NOTE: make read-only in react/preact is almost imposible if we don't include some state management library, in svelte we'll need to add extra logic to handle writable stores (remove subcriptions), I have no idea what happens when returning only the solid accessor (the only we can use read-only is vue via readonly or computed from the ref).

NOTE: this PR should be included only in v1.0.0 major version.

/cc @antfu I removed ssr.noExternal from main plugin, @vite-pwa/workbox-window is ESM-first with dual ESM/CJS package exports.

closes #620
supersedes #623

Copy link

netlify bot commented Dec 31, 2023

Deploy Preview for vite-plugin-pwa-legacy ready!

Name Link
🔨 Latest commit ed83e56
🔍 Latest deploy log https://app.netlify.com/sites/vite-plugin-pwa-legacy/deploys/65c8f31c0cf5dd0008e6bdb6
😎 Deploy Preview https://deploy-preview-634--vite-plugin-pwa-legacy.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@userquin userquin changed the title feat: move to @vite-pwa/workbox-window feat!: move client to @vite-pwa/workbox-window Dec 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

try to expose new version detected
1 participant