React JS – introduction to JSX and Internal Working

What is JSX:–

React JS – introduction to JSX and Internal Working, We will learn about JSX.JSX is One of basic aspect in react.It acts a kind of templating in react, but it is more than that. JSX is a syntactical extension to javascript, it helps to build your UI components. JSX is a preprocessor step that adds XML syntax to JavaScript. You can definitely use React without JSX but JSX makes React a lot more elegant.We must remember always React is a Library not a framework.

JavaScript

1

2

3

4

constelement=<div class="wrapper">

<h1 color="blue"className="sidebar">Hello,world!</h1>

<h2 color="blue"className="sidebar">Hey Guys</h2>

</div>;

This code above is a combination of javascript and HTML. In case of normal coding perspective, it’s unusual. You can’t have javascript and Html together in a single place, but react doesn’t separate the technologies by putting markup and logic in two different places. Instead of that, it separates the concerns, and the concern here is How easy and How good is our UI?