re: Help! I am Overwhelmed With React and It's Preventing Me From Finding A Workflow VIEW POST

re: Hosting (public facing)? I can't install packages onto my shared hosting plan on the fly. I can't ssh into it. No root access. What do I use instea...

React is nothing more than a view library for declaratively rendering complicated client states.

Could you break that down even further maybe? I totally get why OP is puzzled and frustrated. I've done React tutorials and succeeded in all the assignments and still don't 100% get it.

What is it that we need React for which we couldn't do with jQuery, for instance?

When I look up React on Wikipedia it's described as a Javascript Library.

When I look at the history of React I get this weird back-story:

in 2012 Mark Zuckerberg commented, "The biggest mistake we made as a company was betting too much on HTML5 as opposed to native".[29] He promised that Facebook would soon deliver a better mobile experience.

Inside Facebook, Jordan Walke found a way to generate iOS UI elements from a background JavaScript thread.

Which strongly implies that React was invented for iOS native interfaces, not regular HTML websites.


What is it that we need React for which we couldn't do with jQuery, for instance?

There's nothing you couldn't do with jQuery, but React makes keeping track of the "state" of a page about 10000000x easier. It's also generally more performant in complicated UI situations because it does minimal DOM manipulation and does most of its work in memory via what it calls the "virtual DOM".

React lets you code as if you were throwing away the whole page each time something happens and rendering from scratch based on the new situation. If you have an add to cart button and a cart icon displaying the number of items in a cart, with jQuery it's possible for things to get complicated quickly as different actions affect different things. React makes complicated UI pretty simple.

jQuery is much simpler for just dropping in and working with, but React eliminates complexity if you lean in to it.

React Native definitely helped React gain traction and commitment from Facebook. It was a big reason people finally started paying attention, but its true origins are pretty inherent to the problem of generating complex UI. Angular at the time truly sucked, and so did lots of stuff that was pretty popular. React really changed things.

React took good established declarative programming ideas that were already popular in game dev (I don't know this first hand, but I've heard it described this way and it makes sense). Games are an incredibly complex state management problem and they'd solved a lot of these problems before UI development needed to.

About game-dev: Games often use immediate-mode-GUI, which has some overlap with how React works.

code of conduct - report abuse