0
Challenge · 02React Core

JSX

Coreused in ~100% of apps

JSX looks like HTML but it's JavaScript in disguise — and the differences are exactly where beginners get stuck.

Core idea. JSX is syntax sugar that compiles to React.createElement(...) calls; curly braces let you drop JavaScript expressions anywhere in your markup.
Playground, this isn't a screenshot
Live demointeractive
Hello, Aria! 2 + 2 = 4.

Everything in { } is live JavaScript — change the input and the JSX re-renders.

↑ play a little first, then dig in