JavaScript React Basics (retired) First Steps in React Our First Application

Alex Busu
Alex Busu
Pro Student 11,819 Points

Why do you need to wrap the Application function in < /> tags?

I understand that if you don't wrap the Application function in < /> tags it won't work but if you can enter JSX in the ReactDOM.render function and this returns what looks like JSX, why wouldn't just running the function work?

It's frustrating that this isn't explained. Obviously the < /> tags look like HTML, but this makes it apparent that they are functionally not HTML, even if they may used to render HTML. It appears to me that the tags are essentially an alternate constructor syntax.

This article helps some: