Why I like coding in React
React is a JavaScript library (framework) that combines the speed of JavaScript with a novel way of rendering webpages that makes them highly dynamic and responsive to user input. Another unique feature of React is that it can perform on both the client and the server sides.
React is normally paired with a JavaScript syntax extension called JSX. JSX is used with React to describe what the UI (user interface) should look like. JSX resembles a template language, but it comes with the full power of JavaScript and renders to the browser seamlessly when used with a preprocessor, like Babel, that translates the code before it is rendered in the browser.
Here are three reasons I enjoy working with the React library:
- React is intuitive. When React is used in combination with JSX and Babel it is an intuitive library for people familiar with HTML and Javascript. This integration makes the transition from standard HTML and Javascript to React relatively painless. The biggest challenge is "props", the React method for passing content between function and class components.
- React interfaces easily with CSS and popular CSS libraries like Bootstrap.
- React offers a Chrome developer tools extension that makes debugging easier.
If you haven't tried React it is worth the time. You can get a quick overview of the library by going through the React tutorial.
Engineer and Investor
5yDaniel Paschal, good points. I should have discussed other libraries/frameworks as well. Yes, React is just another tool, but fun because the documentation is fairly easy to follow. I frequently wonder how adoption rates would change if documentation was better structured. It seems that broad overviews with plenty of diagrams and pictures that link to specific details would be game changers.
Senior Lead Developer at Internet Brands working with JS, PHP, Postgres, Laravel, React, CSSS/SASS, Jenkins, and Git
5yGood that you offered a link! Helps get people started right away!
Senior Lead Developer at Internet Brands working with JS, PHP, Postgres, Laravel, React, CSSS/SASS, Jenkins, and Git
5yComing from the viewpoint of a veteran dev, I tend to have a very different view of React. It's fun for me in the same way as a long-distance runner decides to run the 400 yard hurdles... just for something else to get in the way. Though it does offer some nice standardization to more fledgeling developers so they can get firing on all cylinders sooner. It is nice to not have to explain the concept of components. It's also important to distinguish that some of the things about it are shared with other platforms. Babel, for instance, isn't unique to React, but is an important part of most installations. Though as you learned from the brilliant Tim Davis, it's important to first use it without all the bells and whistles so you aren't locked into using them all the time. Check out other frameworks in the modern era like Vue or Angular, or go back a bit and try Ember or Meteor. You'll see a lot of these traits are repeated one way or another.