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

Missing Content message flashes when hosted on subdirectory #106

Closed
j-maas opened this issue May 16, 2020 · 1 comment · Fixed by #125
Closed

Missing Content message flashes when hosted on subdirectory #106

j-maas opened this issue May 16, 2020 · 1 comment · Fixed by #125
Projects

Comments

@j-maas
Copy link
Contributor

j-maas commented May 16, 2020

Since I deployed to GitHub Pages, I am reaping the benefit of the quite recently introduced possibility to deploy to a subdirectory, instead of the root path.

Unfortunately, I noticed that there is a "Missing Content" message flashing when I reload the page. This is absent from all pages in elm-pages showcase. I investigated and finally found that this is due to the subdirectory on GitHub pages.

Apparently, the subdirectory feature introduced a regression reintroducing #42.

Reproduction

  1. Clone the elm-pages-starter repo.
  2. Execute npm run build.
  3. Execute npx http-server . -a localhost -p 3000 -c-1 (The difference to the command in npm serve is that we serve . instead of ./dist.)
  4. Open http://localhost:3000/dist
  5. Reload and observe the "Missing Content" flash. You might want to enable throttling in the developer tools.
@j-maas
Copy link
Contributor Author

j-maas commented May 25, 2020

I've debugged the page and it looks like the content.json is fetched and even passed to the Elm app via the contentJson flag. So it appears that this bug is somehow inside Elm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Roadmap
  
Released
1 participant