Code written with JSX will be converted to use React.createElement(). You will not typically invoke React.createElement() directly if you are using JSX. See React Without JSX to learn more.

React.cloneElement(
  element,
  [config],
  [...children]
)
React.cloneElement() is almost equivalent to:

<element.type {...element.props} {...props}>{children}</element.type>
Code written with JSX will be converted to use React.createElement(). You will not typically invoke React.createElement() directly if you are using JSX. See React Without JSX to learn more.

React.cloneElement(
  element,
  [config],
  [...children]
)
React.cloneElement() is almost equivalent to:

<element.type {...element.props} {...props}>{children}</element.type>
React.Children.only() does not accept the return value of React.Children.map() because it is an array rather than a React element.

React.Children.toArray(children)
React.forwardRef accepts a rendering function as an argument. React will call this function with props and ref as two arguments. This function should return a React node.

const FancyButton = React.forwardRef((props, ref) => (  <button ref={ref} className="FancyButton">    {props.children}
  </button>
));

// You can now get a ref directly to the DOM button:
const ref = React.createRef();
<FancyButton ref={ref}>Click me!</FancyButton>;
React.Suspense lets you specify the loading indicator in case some components in the tree below it are not yet ready to render. Today, lazy loading components is the only use case supported by :

// This component is loaded dynamically
const OtherComponent = React.lazy(() => import('./OtherComponent'));

function MyComponent() {
  return (
    // Displays <Spinner> until OtherComponent loads
    <React.Suspense fallback={<Spinner />}>
      <div>
        <OtherComponent />
      </div>
    </React.Suspense>
  );
}
React.createRef creates a ref that can be attached to React elements via the ref attribute.

class MyComponent extends React.Component {
  constructor(props) {
    super(props);

    this.inputRef = React.createRef();  }

  render() {
    return <input type="text" ref={this.inputRef} />;  }

  componentDidMount() {
    this.inputRef.current.focus();  }
}
React.Component is the base class for React components when they are defined using ES6 classes:

class Greeting extends React.Component {
  render() {
    return <h1>Hello, {this.props.name}</h1>;
  }
}
React.Children provides utilities for dealing with the this.props.children opaque data structure.

React.Children.map(children, function[(thisArg)])
Like React.Children.map() but does not return an array.

React.Children.count(children)
The React.Fragment component lets you return multiple elements in a render() method without creating an additional DOM element:

render() {
  return (
    <React.Fragment>
      Some text.
      <h2>A heading</h2>
    </React.Fragment>
  );
}

Recommend

React Top-Level API Reference createElement()

React Top-Level API Reference React.memo

React Top-Level API Reference React.Component

React Passing Functions to Components How can I prevent a function from being called too quickly or too many times in a row? requestAnimationFrame throttling

React Passing Functions to Components How can I prevent a function from being called too quickly or too many times in a row? Debounce

React Passing Functions to Components How can I prevent a function from being called too quickly or too many times in a row? Throttle

React Passing Functions to Components How do I pass a parameter to an event handler or callback? Example: Passing params using data-attributes

React Passing Functions to Components How do I pass a parameter to an event handler or callback?

React Passing Functions to Components Why is my function being called every time the component renders?

React Passing Functions to Components Why is binding necessary at all?

React Passing Functions to Components How do I bind a function to a component instance? Arrow Function in Render

React Passing Functions to Components How do I bind a function to a component instance? Class Properties (Stage 3 Proposal)

React Passing Functions to Components How do I bind a function to a component instance? Bind in Constructor (ES2015)

React Passing Functions to Components How do I pass an event handler (like onClick) to a component?

React Building Your Own Hooks useYourImagination()

React Building Your Own Hooks Using a Custom Hook Tip: Pass Information Between Hooks

React Building Your Own Hooks Using a Custom Hook

React Building Your Own Hooks Extracting a Custom Hook

React Building Your Own Hooks

React Conditional Rendering Preventing Component from Rendering

React Conditional Rendering Inline If-Else with Conditional Operator

React Conditional Rendering Inline If with Logical && Operator

React Conditional Rendering Element Variables

React Conditional Rendering

React Composition vs Inheritance Specialization

React Composition vs Inheritance Containment

React Using the State Hook Recap Tip: Using Multiple State Variables

React Using the State Hook Recap Tip: What Do Square Brackets Mean?

React Using the State Hook Recap

React Using the State Hook Updating State

React Using the State Hook Reading State

React Using the State Hook Declaring a State Variable

React Using the State Hook What’s a Hook?

React Using the State Hook Hooks and Function Components

React Using the State Hook Equivalent Class Example

React Using the State Hook

React Handling Events Passing Arguments to Event Handlers

React Handling Events

React Hello World

React Rules of Hooks Explanation

React Rules of Hooks ESLint Plugin

React Introducing Hooks

ReactDOMServer Reference renderToStaticNodeStream()

ReactDOMServer Reference renderToNodeStream()

ReactDOMServer Reference renderToStaticMarkup()

ReactDOMServer Reference renderToString()

ReactDOMServer

React Testing Recipes Multiple Renderers

React Testing Recipes Snapshot Testing

React Testing Recipes Timers

React Testing Recipes Events

React Testing Recipes Mocking Modules

React Testing Recipes Data Fetching

React Testing Recipes Rendering

React Testing Recipes act()

React Testing Recipes Setup/Teardown

React Rendering Elements Updating the Rendered Element

React Rendering Elements Rendering an Element into the DOM

React Rendering Elements