News for hackers. Stuff that matters.
Re:Gatsby – A Static Site Generator for React by the_duke on Wednesday July 20, 2016 @10:45AM (#12129370)
The same reason why anybody is using React instead of full site reloads.

Only do a small (api) data request per page, faster page transitions, a more interactive experience.

Just think of the site generator as a static api backend for the the JS frontend.

Re:Gatsby – A Static Site Generator for React by jamra on Wednesday July 20, 2016 @10:49AM (#12129421)
Why not just have HTML generated at some earlier time? It's faster, can be cached, and does the same thing.

I'm a little confused about no page transitions. I don't know why that is a problem that needs solving. Also hot reloading.

Re:Gatsby – A Static Site Generator for React by enraged_camel on Wednesday July 20, 2016 @11:00AM (#12129510)
It comes down to user experience. There's a categorical difference between having to do regular transitions and full-page reloads, and no page transitions and hot reloading. The latter is more overhead from an initial bandwidth and processing perspective, but results in zero-latency interactions, which can be important.

Is a JS framework the best way to achieve that? Maybe, maybe not. There are many factors to consider. I just don't think it's a matter of "this isn't a problem that needs solving."

Re:Gatsby – A Static Site Generator for React by virtualwhys on Wednesday July 20, 2016 @01:48PM (#12130965)
> It comes down to user experience

Indeed, it does. My experience visiting SPAs is frankly one of annoyance. Somehow, with 32GB of memory, dual SSDs and an i7 extreme processor, the browser grinds to a crawl with at least 1 CPU core maxed out for however long it takes for the extraneous (to me) transition/effect to complete. As a side effect the CPU fan kicks in for my auditory pleasure.

Compare that to a traditional web page where the browser only needs to handle a small fragment of html after initial page load, which typically makes for blazing fast page transitions, indistinguishable from SPA transitions.

I get the benefit of offloading work to the client when scalability is an issue, but for a static blog site? Not so much, I'd say using React in this case is less about the user experience and more about the developer's.

Re:Gatsby – A Static Site Generator for React by escapee on Wednesday July 20, 2016 @07:01PM (#12133185)
> My experience visiting SPAs is frankly one of annoyance.

I will echo this. SPAs can be great when done well, but my experience with them as a user suggests they're easy to do poorly.

Re:Gatsby – A Static Site Generator for React by jamra on Wednesday July 20, 2016 @05:29PM (#12132671)
I agree with you. Plus, if you use Cloudflare, your server may not even take the burden of the request. They will do the caching of static content for you.
Re:Gatsby – A Static Site Generator for React by spdustin on Wednesday July 20, 2016 @11:05AM (#12129557)
I dunno...

Reloading 10K of (likely cached in memory and compressed by server) HTML to load a new page of HTML when a user clicks a link, with a browser that respects caching headers and so doesn't bother reloading content supporting images/UI element sprite sheets/CSS/JavaScript is never the wrong thing to do with "static" sites. In many cases, it's the most right.