Fix jsonification of message, try sending reply immediately upon receiving message event
Test / test (push) Failing after 54s
Details
Test / test (push) Failing after 54s
Details
This commit is contained in:
parent
16250ef533
commit
5741b9fee2
|
|
@ -106,7 +106,7 @@ function TackUpNow({
|
|||
{() => (
|
||||
<>
|
||||
{messages.map((message, index) => (
|
||||
<div key={index}>JSON.stringify(message)</div>
|
||||
<div key={index}>{JSON.stringify(message)}</div>
|
||||
))}
|
||||
{isInstalled ? (
|
||||
<div>Your Notifications</div>
|
||||
|
|
|
|||
|
|
@ -52,6 +52,10 @@ export default function start(self: ServiceWorkerGlobalScope) {
|
|||
const waitEvent = event as ExtendableEvent
|
||||
waitEvent.waitUntil(
|
||||
(async () => {
|
||||
await sendMessage({
|
||||
message: "Got message",
|
||||
})
|
||||
|
||||
if (
|
||||
"type" in event &&
|
||||
event.type === "subscribed" &&
|
||||
|
|
|
|||
Loading…
Reference in New Issue