Sample App With ASP.NET Web API and ReactJS
We have just started a sample app for demonstrate building apps with ReactJS and ASP.NET Web API. An early version of the app can available on github at https://github.com/shijuvar/react-aspnet . Please note that the ReactJS version of the app is not a final version, but it is an early version which will continuously refactor with a proper Flux architecture. The RESTful API written with ASP.NET Web API 2.
Why ReactJS
We have been using MVC for building web apps and REST services for long time. At server-side, MVC is really good choice for building web apps. At one day, someone else has started to use MVC for building client-side apps too and provided a MVC framework for front-end apps. Then everyone followed that convention for solving all kinds of problems in client-side apps. IMHO, using MVC for client-side apps is really bad idea and I believe that MVC doesn't scale at larger cleint-side apps. The real beauty of ReactJS is that it is keeping away from existing conventions and patterns and trying to bring some practical solutions for solving the problem around building larger front-end apps which can be easily scale-up with recommended architecture practices such as Flux.
React is a JavaScript library developed by Facebook and Instagram team, for building user interfaces. The entire front-end of Instagram web site and some parts of the Facebook web site built with ReactJS. Interestingly, you can use ReactJS with other front-end frameworks such as AngularJS and EmberJS. You can use ReactJS as the view part along with MVC frameworks. But, in practice, I don't recommend to use ReactJS with traditional MVC frameworks. ReactJS introduces Virtual DOM, which is awesome part of the ReactJS library and it enables high performance for the rendering of UI. ReactJS provides better performance for the UI rendering than MVC frameworks such as AngularJS and EmberJS. You can build re-usable UI components with the Virtual DOM abstraction and later we can compose these components on the actual DOM. For scaling front-end apps, we can use Flux architecture which is basically set of architecture practices, that provides data flows in a single direction. I have evaluated BackboneJS, EmberJS, AngularJS and React and highly recommend React for building user interfaces.
Source Code
The source code is avaialble in github at https://github.com/shijuvar/react-aspnet