Re: [w3c/ServiceWorker] New "setup" lifecycle for service worker (#1576)

> These codes are equivalent, just the style is different. If you wait for data, then resolve(data). If you wait for the preparation to be completed, then resolve().

Let me explain more. In my real code, I parse the whole data, and set two global variables. So I think of the `init` method as a setup phrase, not a single data. If it is a single data, your code style is more reasonable.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/ServiceWorker/issues/1576#issuecomment-814749834

Received on Wednesday, 7 April 2021 09:14:14 UTC