It is syntax extension to javascript. JSX remind template lnaguage. but it completely take pawoer of javascript.
JSX produces React "elements". We will explore rendaering to DOM in the next section.
Embedding Expressions in JSX
In the example below, we declare a variable called name and then use it inside JSX by wrapping it in curly braces:
const name = 'Sayed Enam';
const element =
Hello, {name}
;ReactDOM.render(
element,
document.getElementById('root')
);
Top comments (0)