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

Shouldn't InstallEvent has a constructor? #1713

Closed
skyclouds2001 opened this issue Apr 22, 2024 · 2 comments · Fixed by #1729
Closed

Shouldn't InstallEvent has a constructor? #1713

skyclouds2001 opened this issue Apr 22, 2024 · 2 comments · Fixed by #1729

Comments

@skyclouds2001
Copy link

skyclouds2001 commented Apr 22, 2024

current the definition for InstallEvent does not has a constructor, this is different from other event interfaces and is quite uncommon, should it also define with a constructor, too?

image

relates with mdn/browser-compat-data#22870

@skyclouds2001 skyclouds2001 changed the title Should InstallEvent has a constructor Should InstallEvent has a constructor field Apr 22, 2024
@skyclouds2001 skyclouds2001 changed the title Should InstallEvent has a constructor field Shouldn't InstallEvent has a constructor? Aug 5, 2024
@skyclouds2001
Copy link
Author

but interestingly, in browser implement InstallEvent is constructible

image

test in https://worker-playground.glitch.me/

@mkruisselbrink
Copy link
Collaborator

Yes, I believe this is an oversight in the spec that was missed when InstallEvent was added in #1701. I can't think of any reason why we shouldn't have a constructor.

sisidovski added a commit to sisidovski/ServiceWorker that referenced this issue Sep 27, 2024
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 a pull request may close this issue.

2 participants