February 24, 2015 · Front-end JavaScript React Facebook React

Trying Facebook React: CSS Color Names App

Finally, I've been able to give myself some time to try React. It's been fun to playing with. I'm looking forward to use it in actual products.

What is Facebook React?

Heres from the Facebook React Docs:

React is a JavaScript library for creating user interfaces by Facebook and Instagram. Many people choose to think of React as the V in MVC.

So, what does it means? It means that it's not another new JavaScript MVC. It's different from Ember, Angular or Backbone. It can be used with one them, served it as the View in the framework or it can be used independently. What I love about React is, its challenging the common pattern that most people use for templating in JavaScript. You can see Pete Hunt video on Youtube talking about the concept of React.

First attempt on React: "CSS Color Name App"

The idea of the app is to list CSS names and display it with a preview box. There is 146 colors in the list. 10 will be chosen randomly at the initial load. You can add more colors or sort the colors by the date appearance of the color or by the name of the color. The random colors is not necessarily unique, so some color can appear twice or more.

Therea are few things that I learned from creating app.

Thats it I think. You can play with this furthermore if you want to in My Codepen.

Update on Feb 27, 2015 — Theres an updated post on this, see React Demo: CSS Color Names v.02.

Comments powered by Disqus