React - Element

> (World Wide) Web - (W3|WWW) > Javascript (Js|ECMAScript) > React

1 - About

An element is a node in the React tree (React DOM implementation).


3 - Type

React has two type of element

4 - Feature

4.1 - Immutable

React elements are immutable.

Once you create an element, you can't change its children or attributes. An element is like a single frame in a movie: it represents the UI at a certain point in time.

5 - Property

5.1 - Attribute

All DOM properties and attributes (including event handlers) should have a camelCased name

For example, the HTML attribute tabindex corresponds to the attribute tabIndex in React. The exception is aria-* and data-* attributes, which should be lowercased.

5.2 - Attribute value

Concatenate in Jsx Example:

<g transform={"translate("+margin.left+",0)"} />

6 - Management

6.1 - Create

The only element that you needs to create inside React is a component. html react element are built-in element.

See component creation on how to create a component.

6.2 - Render

6.3 - Update

6.4 - Loop

7 - Documentation / Reference