I may understand what you mean but I'm convinced that your target audience is not going to come away with the same understanding.
write the same format of code as HTML
That phrasing alone is enough to establish a false equivalence between JSX and HTML. And to some degree it's only valid as long as you are talking about React's DOM element components. User components compose those DOM components. Container components may only compose User components without adding any additional DOM components. Providers have no equivalence in the DOM at all.
JSX is what makes React declarative. HTML happens to be declarative. JSX is XML. Both XML and HTML derived from SGML.
JSX composes React Components
HTML composes markup from HTML elements
The fact that a component's position in the component tree is linked to the position of the rendered content in the DOM tree is a leaky abstraction.
React's entire premise is to reuse React components in React Native. React Native is all components and JSX; no HTML, no DOM;
Hi 👋
This is Suchintan a Full Stack Developer with MERN stack.
Want to know more about me?
Connect me on - https://www.linkedin.com/in/suchintan-das-b698bb1b8/
Thanks peerreynders for the feedback. Yes, there a case that people take away a wrong concept by misunderstanding this line. I will edit this line on the blog so that atleast no misconception is spread.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I may understand what you mean but I'm convinced that your target audience is not going to come away with the same understanding.
That phrasing alone is enough to establish a false equivalence between JSX and HTML. And to some degree it's only valid as long as you are talking about React's DOM element components. User components compose those DOM components. Container components may only compose User components without adding any additional DOM components. Providers have no equivalence in the DOM at all.
JSX is what makes React declarative. HTML happens to be declarative. JSX is XML. Both XML and HTML derived from SGML.
The fact that a component's position in the component tree is linked to the position of the rendered content in the DOM tree is a leaky abstraction.
React's entire premise is to reuse React components in React Native. React Native is all components and JSX; no HTML, no DOM;
Thanks peerreynders for the feedback. Yes, there a case that people take away a wrong concept by misunderstanding this line. I will edit this line on the blog so that atleast no misconception is spread.