Hi
Does your app load the SDK as well as placing the code in your template index file.
I just seem to get it loading twice on every page and this error in the console
OneSignal: The web push SDK is included more than once. For optimal performance, please include our SDK only once on your page.
cheers