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.

Not getting chunks SSR

See original GitHub issue

Hi, got a problem here.

Using ssr with ts-node ts server, and not getting any loadable chunks. Getting this in extactor:

​get -> scriptTags <script>window.__LOADABLE_REQUIRED_CHUNKS__ = [];</script>
<script async data-chunk="app" src="/bundle.app.js"></script>
​get -> linkTags <link data-chunk="app" rel="preload" as="script" href="/bundle.app.js">
​get -> scriptTags <script>window.__LOADABLE_REQUIRED_CHUNKS__ = [];</script>
<script async data-chunk="app" src="/bundle.app.js"></script>
​get -> linkTags <link data-chunk="app" rel="preload" as="script" href="/bundle.app.js">

but app loads fine and loadable components load fine too.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:16 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
gregbergecommented, Feb 14, 2019

@bertho-zero the context is exposed (https://github.com/smooth-code/loadable-components/blob/master/packages/component/src/index.js#L16), if you want to use it, you can use it, you will not be fired 😉.

1reaction
gregbergecommented, Feb 11, 2019

I understand your issue. Be careful of building your app correctly, server-side modules must be externals. I think we should document it. See https://github.com/smooth-code/loadable-components/blob/master/examples/server-side-rendering/webpack.config.babel.js#L40

I created an issue: https://github.com/smooth-code/loadable-components/issues/231

Read more comments on GitHub >

github_iconTop Results From Across the Web

Not getting chunks SSR · Issue #193 - GitHub
Hi, got a problem here. Using ssr with ts-node ts server, and not getting any loadable chunks. Getting this in extactor: ​get ->...
Read more >
Developers - Not getting chunks SSR - - Bountysource
Hi, got a problem here. Using ssr with ts-node ts server, and not getting any loadable chunks. Getting this in extactor:
Read more >
[Webpack][React] On SSR with code-splitting how I can get the ...
The problem is that when I reload one of the pages the needed css chunks are loaded once rendered and not linked directly...
Read more >
Lazy load on React SSR with Code Splitting - Medium
Webpack Split Chunks is a great strategy to optimise your application. It will split your big ugly bundle into smart and reusable chunks...
Read more >
Server Side Rendering - Loadable Components
The collectChunks method wraps your element in a provider. ... Just make sure not to use it on the client-side. ... Disable SSR...
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