DEV Community

Discussion on: Why use React instead of JavaScript HTML and CSS

Collapse
 
ben profile image
Ben Halpern

React is a fairly brilliant layer of API for managing how things change on a page or a part of a page.

If you want to check a box that updates a number, you could do it with JavaScript and the DOM pretty easily, but now your page is in a new "state", and managing that with any complexity is a real nightmare.

React allows you to manage state and render different outcomes based on what the state is. It's a real joy if you get it right.

That being said, there are definitely a lot of instances of people using React, or whatever their favorite view library for everything, introducing build-step complexity and possible performance hits when it's just not worth doing so.

If managing the state of a page is the challenge you're facing, React is a great choice.

Collapse
 
mraza007 profile image
Muhammad

I was thinking to revamp my portfolio in React

Collapse
 
aravindballa profile image
Aravind Balla

I built mine in React. Rather in GatsbyJS, which is a static site generator.

This is the repo -> github.com/aravindballa/website2017

Thread Thread
 
mraza007 profile image
Muhammad

Looks Cool

Collapse
 
thejohnstew profile image
John Stewart

Everything Ben said! Also if you are interested in using React for your portfolio take some time and get to know Gatsby.js. I recently rebuilt my website in it and it really is amazing what you can build.