News for hackers. Stuff that matters.
Re:A static website with React by kennu on Friday February 17, 2017 @11:37AM (#13669521)
I think we are taking about websites that can be hosted on a static file server like Amazon S3/CloudFront, but which also have all the dynamic features of React available for building a rich and complex UX. For instance, when working with Phenomic (which uses Webpack), it's very easy to add any necessary React components to your project simply with npm install / yarn add. So it's really a marriage of Markdown based content publishing and interactive client-side UX.
Re:A static website with React by paulddraper on Friday February 17, 2017 @03:49PM (#13671594)
I eternally have this misunderstanding. I think static means unchanging.

In this context, it means static HTTP responses, but dynamic HTML/DOM.

I want a word to mean really static.

Re:A static website with React by bloodyowl on Friday February 17, 2017 @05:29PM (#13672278)
Hello,

I'm in the core Phenomic team.

The idea in Phenomic is that we generate for each page:

- the HTML entry point, rendered like it would be with ReactDOMServer - the data-requirements of the page

That lets us offer the following: - Any page is accessible directly, without runtime (which has advantages regarding performance and SEO) - Navigation works even if JS is disabled - If JavaScript is enabled, the runtime just loads the minimum required data for the next page to display and renders it

Phenomic really is static, it just uses a few techniques that we learnt from the modern front-end development workflows and capabilities :)

Re:A static website with React by paulddraper on Friday February 17, 2017 @06:38PM (#13672657)
Neat. Thanks for the info!
Re:A static website with React by cies on Friday February 17, 2017 @04:33PM (#13671877)
In this context some HTTP responses are static. The static part of the website.

But the React app can also start consuming all kinds of webservice.

This way (1) a large part of content can be served as prerendered static HTTP responses (HTML, CSS, JS). (2) Static content not initially loaded can be served as JSON (as seen in the presentation). And (3) dynamic content (e.g. real time comments or a chat) can be non-static (one or more webservices, possibly on WebSocket thereby going beyond HTTP).

I think this may be very interesting when "big mostly static content", "need for modern web tech" and "big traffic" meet.

Re:A static website with React by kmonsen on Friday February 17, 2017 @12:03PM (#13669772)
Yes, the word static is a bit overloaded here.
Re:A static website with React by gkya on Friday February 17, 2017 @03:09PM (#13671286)
Misused, rather. This is dynamic pages, client side.