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.

[server-side-rendering] - server doesn't re-fetch modules

See original GitHub issue

Step to reproduce

In a first terminal - Terminal 1

  • cd server-side-rendering/website1
  • yarn install
  • yarn build && yarn serve

In a second terminal - Terminal 2

  • cd server-side-rendering/website2
  • yarn install
  • yarn build && yarn serve

at this step : everything is working fine and header component is loaded through localhost:3002

Capture d’écran 2020-05-15 à 11 49 32 AM Capture d’écran 2020-05-15 à 11 49 46 AM

Now try to update header component (website2) without touching host (website1)

Terminal 2

  • CTRL+C
  • on website2/src/components/SomeComponent.js update line 13 with “Zack is awesome
  • yarn build && yarn serve

Actual results on localhost:3001 - Client side you will see “Zack is awesome” however on the DOM you will still see “Header”

Result expected we should have “Zack is awesome” on Client & DOM without having to rebuild HOST(website1)

Capture d’écran 2020-05-15 à 11 50 27 AM Capture d’écran 2020-05-15 à 11 50 32 AM

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:3
  • Comments:22 (21 by maintainers)

github_iconTop GitHub Comments

2reactions
7rulnikcommented, Jun 9, 2020

BTW, the whole solution with the same disk looks weird. I believe that people mostly use docker containers. So we need the way to load remote chunks by HTTP on the server-side

1reaction
ScriptedAlchemycommented, Jun 15, 2020

changes are, the next rewrite on streamed systems will resolve this. We are actively rewriting it. I’m also working with Google, so we plan to introduce programmatic memory management into V8.

If anyone wants to collaborate on this, I’m willing to talk about it in more depth. But for the time being, i have alternative solutions that are part of proprietary tools. They take a very different approach but this is possible to achieve imo

Read more comments on GitHub >

github_iconTop Results From Across the Web

Server side rendering not working with modules lazy ...
There are several reasons why the body tag of your angular app fails to render on the server side. Here's a checklist:.
Read more >
Data Fetching: getServerSideProps
If you export a function called getServerSideProps (Server-Side Rendering) from a page, Next.js will pre-render this page on each request using the data ......
Read more >
Step By Step Guide to Enable Hot Module Replacement in ...
The problem in hot reloading a server side rendered app is that we have no way to connect it to the webpack-dev-server which...
Read more >
Server Side Rendering
npm install @loadable/server && npm install --save-dev ... module.exports = { ... Streaming rendering is not compatible with prefetch <link> tags.
Read more >
Understanding Next.js Data Fetching for Beginners
SSR - Server-Side Rendering will run a special function to fetch data from the API with every page request on the server-side (before...
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