Closed daan-nguyen closed 7 years ago
@daan-nguyen awesome! I am really glad you're enjoying it. I'd love to hear about anything you end up building with it 😄 .
Nice catch on the server-side rendering!!! That is great. Hey, if you're able to, can you submit a PR to fix this? It'd be really helpful. If not, no worries. It might take me a bit to get to it as I am just starting a new job.
Thanks again and please let me know if you have any questions or more issues.
@RyanCCollins PR created! Just removed the index.html
from being generated as part of production build since SSR is available. The production template would then be the Html.js
file in server/utils
.
Future improvement may be to generate the Html.js
file from a template file in the template
folder, letting all templates live in one place logically.
Nice job fixing this! #63 has been merged and closed.
It appears when making a request to the root entry (
localhost:1337/
orlocalhost:1337/index.html
) the server side rendering doesn't initiate.I think it's this part here in the app.js. The static file serving is finding the
index.html
first, so it skips the code that will provide server side rendering. Hitting the/about
route directly seems to work correctly as the file doesn't resolve on static file serving.You can verify this by just deleting or renaming the
index.html
file inserver/public
.PS. Great boilerplate project! We are evaluating a few atm and this one is definitely our favourite, esp like the generators. The recent
sans-apollo
branch has been really helpful since we aren't in a position to make use of it.