I'm working on PWA on my page, and I'm following 100% this simple codelab - https://codelabs.developers.google.com/codelabs/add-to-home-screen/#0 and everything works fine (on exmaple code used, and also on my own webpage), but only when i test it on localhost. after deploying it on github pages, i got lots of errors:
GET https://[myusername].github.io/manifest.json 404 ()
(ie. there may be something wrong with paths, as there should be project name before manifest file i guess)Manifest: Line: 1, column: 1, Unexpected token.
(in devtools i can see there's although it's normal json file and it's working fine on my localhost);TypeError: Failed to register a ServiceWorker: A bad HTTP response code (404) was received when fetching the script.
- and after clicking "Add to homescreen" in devtools, i got:
Manifest: Line: 1, column: 1, Unexpected token.
andSite cannot be installed: the manifest could not be fetched, is empty, or could not be parsed
.
Any ideas? I don't know if i'm doing something wrong or there's something wrong with github pages...