-
Notifications
You must be signed in to change notification settings - Fork 313
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
ready promise is kind of weird after you call unregister() #1279
Comments
I agree this is weird. I think our hands are tied because .ready is a property, so it always needs to return the same promise. There is some historical discussion at #223 and https://groups.google.com/a/chromium.org/d/msg/blink-dev/jjh4KUS0cS0/xA8_F904UeQJ I'm not too sure why #223 went with a property instead of a method. #223 says "it's just a state transition". I guess we didn't consider that unregister() can transition you back to the "not ready" state. Of course this is all a bit of an edge case, I don't think it's caused problems in the wild, and sites can detect it by checking if registration.active is null. |
Adding two cents: the lifecycle API's of SW are either too high-level or too low-level. High-level APIs like For the most part - this isn't an issue until you want to take advantage of |
F2F: see #1278 |
Consider this:
Does this make sense to developers? I find it really weird. Related to #1278.
The text was updated successfully, but these errors were encountered: