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

[Bug]: The notifications are not delivered, when using Angular pwa and OneSignal together #43

Open
ertugrulbakidal opened this issue Nov 14, 2023 · 3 comments

Comments

@ertugrulbakidal
Copy link

ertugrulbakidal commented Nov 14, 2023

What happened?

Although I registered OneSignal different scope than PWA service worker, It's causing issues. In the devtools service workers tab this can be observed that OneSignal service worker is stopped accordingly the notifications are not delivered.

What browsers are you seeing the problem on?

Chrome (Chromium)

What operating system are you running?

Windows 11

Steps to reproduce?

Node version: 18.16.0
Angular version: 16.1.0
NPM version: 9.5.1
onesignal-ngx version: 2.0.1

I created a repo to reproduce the issue. https://github.com/ertugrulbakidal/AngularWithOneSignal

- Change the OneSignal app id
- Install dependencies
- run ng build
- npm install --global http-server
- npx http-server -p 4200 -c-1 .\dist\angular-pwa-with-one-signal\

What did you expect to happen?

The OneSignal notifications should be delivered while using Angular PWA

Relevant log output

No response

@jkasten2
Copy link
Member

@ertugrulbakidal Thanks for reporting. I believe there is a race condition bug in the OneSignal-Website-SDK where it can sometimes pick up the wrong Service Worker when registering for push. This is something we are looking into.

@ryanvu
Copy link

ryanvu commented Jul 4, 2024

Has there been any progress on this?

My Service worker is attached, but not receiving Push Notifications on Chrome

@marmotz
Copy link

marmotz commented Sep 21, 2024

Almost 1 year and still no solution or workaround?

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

No branches or pull requests

4 participants