question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Bug] SSR does not seem to work on new project

See original GitHub issue

Reporting a bug?

Creating a new project with react-static create and selecting basic, and building with yarn build and serving yarn serve, when we see source of /about page, it shows source of / home page.

Environment

Run and copy the result of:
OS: macOS 10.14.3
CPU: (4) x64 Intel(R) Core(TM) i5-5257U CPU @ 2.70GHz
Memory: 144.34 MB / 8.00 GB
Shell: 5.3 - /bin/zsh

Steps to Reproduce the problem

As described in Reporting a bug section.

Expected Behavior

The source should only contain HTML code for that particular route.

Reproducible Demo

As described in Reporting a bug section.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:9 (7 by maintainers)

github_iconTop GitHub Comments

2reactions
boennemanncommented, Mar 20, 2019

Holy smokes – I found it. The story of how two tiny characters can mess up an entire day worth of work …

I was digging and digging, when I finally realized there is a difference between the files inside my dist folder, and the ones view-source: is showing.

Turns out the basic template passes the -s flag to serve. The reason for this? I have no idea.

      -s, --single                        Rewrite all not-found requests to `index.html`

Bingo, that’s it.

The -s flag is not present for nozzle/nozzle.io, which explains that it started working for @atulmy once he used that as a template.

0reactions
boennemanncommented, Mar 20, 2019
Read more comments on GitHub >

github_iconTop Results From Across the Web

Using Non-SSR Friendly Components with Next.js
no -ssr is a React component that wraps non-SSR components. This wrapper makes it easy to deal with client-only components when working with...
Read more >
Fate/Grand Order Official USA Website
* It is possible that the game will not work on some devices, even with the recommended version or higher. Supported RAM requirements...
Read more >
Angular universal Web App with SSR randomly slow (15s per ...
Hi,. We are trying to publish an SSR (Server side rendering) Angular App on an Azure Web App running on Node 14. Everything...
Read more >
VueJS SSR V8JS Symfonybug Jquery - Stack Overflow
If i test with this project github.com/ChrisDBrown/symfony4-vuejs-ssr inject jquery and boostrap, same bug and same error... It's not possible ...
Read more >
A game breaking bug in Tower of Fantasy : r/gachagaming
When he log in back he found out that he can't use his newly got SSR. ... But the funny thing is after...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found