- JSX is an XML/HTML-like syntax used by
React
that extends ECMAScript so that XML/HTML-like text can co-exist with JavaScript/React
code.
- The syntax is intended to be used by preprocessors (i.e., transpilers like Babel) to transform HTML-like text found in
JavaScript
files into standard JavaScript objects that a JavaScript engine will parse.
const nav = (
<ul id="nav">
<li><a href="#">Home</a></li>
<li><a href="#">About</a></li>
<li><a href="#">Clients</a></li>
<li><a href="#">Contact Us</a></li>
</ul>
);