Hacker News new | ask | show | jobs
by fiatjaf 3157 days ago
What is code-splitting? Is it asynchronous loading of components?

If you're interested in a React-based static site generator that does that: https://github.com/fiatjaf/sitio

1 comments

It means load only the code for the page/route that you are visiting and not the code of entire site.

Suppose you visit only example.com/about-us page then why should the server load example.com, example.com/faq, example.com/blog code together with it?

I hope you got the point of code-splitting. :)

A new name for a very old concept. People keep inventing these things...