20/02/2025, 09:07 Built-in React APIs – React
v19
API REFERENCE
Built-in React APIs
In addition to Hooks and Components, the react package exports
a few other APIs that are useful for defining components. This
page lists all the remaining modern React APIs.
createContext lets you define and provide context to the child
components. Used with useContext .
forwardRef lets your component expose a DOM node as a ref to the
parent. Used with useRef .
lazy lets you defer loading a component’s code until it’s rendered for the
first time.
memo lets your component skip re-renders with same props. Used with
useMemo and useCallback .
startTransition lets you mark a state update as non-urgent. Similar to
useTransition .
act lets you wrap renders and interactions in tests to ensure updates
have processed before making assertions.
Resource APIs
Resources can be accessed by a component without having them as part of
their state. For example, a component can read a message from a Promise or
read styling information from a context.
To read a value from a resource, use this API:
use lets you read the value of a resource like a Promise or context.
https://react.dev/reference/react/apis 1/3
20/02/2025, 09:07 Built-in React APIs – React
function MessageComponent({ messagePromise }) {
const message = use(messagePromise);
const theme = use(ThemeContext);
// ...
}
PREVIOUS
<Suspense>
NEXT
act
Copyright © Meta Platforms, Inc
uwu?
Learn React API Reference
Quick Start React APIs
Installation React DOM APIs
Describing the UI
Adding Interactivity
Managing State
Escape Hatches
Community More
Code of Conduct Blog
Meet the Team React Native
https://react.dev/reference/react/apis 2/3
20/02/2025, 09:07 Built-in React APIs – React
Docs Contributors Privacy
Acknowledgements Terms
https://react.dev/reference/react/apis 3/3