4 ms·
John Resig (jQuery creator) is one of the chief architects at there, and yet you see, this line: Never use jQuery for DOM manipulation Nice.
by tzury 11y ago
John Resig (jQuery creator) is one of the chief architects at there, and yet you see, this line:
Never use jQuery for DOM manipulation
Nice.
- albertoleal 11y agoThis is a React style guide; which implies that React does all (if not, most) of the DOM manipulations for you. jQuery, as a library, have useful utilities that that do not do DOM manipulations.
- doppel 11y agoI think the implication is not that jQuery is bad for DOM manipulation, but that you should leave DOM manipulation to React to have a 1:1 relation between the held state in React and the actual DOM. In other words: Do not manipulate the DOM outside of React.
- Cshelton 11y agoReact keeps all of the "DOM" stuff in memory. Thus it is inefficient and unnecessary to use jQuery to do anything to the DOM.