Creating React components

Similar jQuery widget and AgularJS directives there is React.js, which is  very useful library for creating interface components. However, it is not a complete framework like AngularJS or Ember.js.

The way to think about React.js is by thinking about interface components: everything is a component and a component may be composed of one or more components.

See the following figure:

Creating React components

Screenshot simulating React.js components

Let's create the components one by one for a better understanding:

  1. Inside the client folder, create a new folder called js.
  2. Inside the js folder, create a new file called review.js and add the following content: ...

Get Node.js 6.x Blueprints now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.