-
Notifications
You must be signed in to change notification settings - Fork 102
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
manifest.json conflict #12
Comments
For example, when I faced with #12, I just saw `error` in console, which is not helpful at all. After debugging I saw that real error was: > DOMException: Registration failed - gcm_sender_id not found in manifest We need to add such details to error so it will be more informative.
Thanks for the issue. I will look over into it. Seems like a improvement that should be made. It needs some documentation also! |
I think we should use existing <link rel="manifest" href="{% static 'core/js/manifest.json' %}"> Additionally adding one line to template is not a problem. |
@arogachev |
Site can already contain
manifest.json
file. For example if you use favicon generator it can be like this:And it's already included in
head
section in layout template along with other favicons related images:If I include
{% webpush %}
after favicons, it's ignored and I get the error about missinggcm_sender_id
which is needed for Chrome. If I placed it above favicons section - it works, but seems like only first manifest is loaded (site / app can have only onemanifest.json
), further declarations are ignored so favicons will not work correctly.Probably the order in template doesn't always matter (the order of loading by browser does), but anyways two
manifest.json
declarations can cause conflict.As a current workaround, I overrided
webpush.html
template, removed manifest declaration from there and addedgcm_sender_id
to existingmanifest.json
.I think we need an option to use existing
manifest.json
instead of creating new one.The text was updated successfully, but these errors were encountered: