3 ms·
As I go over the impressive list of big sites adopting React [1] I feel there must be something wrong with this current survey [2], which states a mere 67 of th
by ezequiel-garzon 11y ago
As I go over the impressive list of big sites adopting React [1] I feel there must be something wrong with this current survey [2], which states a mere 67 of the top 10000 sites are using it. Any insight will be welcome.
[1] https://github.com/facebook/react/wiki/Sites-Using-React https://github.com/facebook/react/wiki/Sites-Using-React
[2] http://trends.builtwith.com/javascript/javascript-library http://trends.builtwith.com/javascript/javascript-library
- chrischen 11y agoWhile easier than before to do server side rendering, it's still non trivial to do a react app that preserves SEO and renders on the server if your app isn't already a nodejs app. It would require running either V8 to render on the server behind whatever language your backend is already written in, or calling node to serve your backend, relegating your existing backend to an API (and tying the backend rendering to your API along with the Frontend to use the same API isn't simple either).
- dominic_cocch 11y agoThat is definitely one limiting aspect for some places. We actually have a similar issue, since we're a Rails shop first and foremost. Luckily there are a few tools we can use to make it work well with Rails. Maybe a future post! I also think jQuery and other libraries with large usage are kind of Swiss army knives, so more people have more use for them. I do believe over time React will become as pervasive as jQuery. Or possibly even the DOM api will eventually allow a similar style of building things natively. This seems to be happening to jQuery now :)
- girvo 11y agoIndeed. We had to tackle this for Expedia's Viewfinder[0] (which was done by utilising nodejs as the server), and we're tackling it again for another project that has it's server-side rendering done in PHP. Interestingly, we are leveraging the v8js PHP plugin to be able to execute JS from inside a PHP context, sharing variables between them as needed. Though I'm not convinced its the perfect way of tackling this problem, there's still a lot of quirks and bugs. [0] https://www.expedia.com/pictures https://www.expedia.com/pictures
- chrischen 11y agoI looked into another alternative: dnode, although I think I'll still stick with V8js for now. I don't think it's avoidable unless you want to switch to a Nodejs API server as well.