Front end developer specialising in JavaScript and React. Experienced in all aspects of modern front end development. Passionate about making accessible, secure and performant software.
According to the MDN docs on ExtendableEvent.waitUntil() it prevents the service worker from terminating until the work inside the function is done. This is because the work inside the function is asynchronous, it could potentially take many seconds to complete.
Essentially it just waits for the promise to be fulfilled.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
According to the MDN docs on ExtendableEvent.waitUntil() it prevents the service worker from terminating until the work inside the function is done. This is because the work inside the function is asynchronous, it could potentially take many seconds to complete.
Essentially it just waits for the promise to be fulfilled.