Add-ons Edit on GitHub

React.addons is where we park some useful utilities for building React apps. These should be considered experimental but will eventually be rolled into core or a blessed utilities library:

  • TransitionGroup and CSSTransitionGroup, for dealing with animations and transitions that are usually not simple to implement, such as before a component's removal.
  • LinkedStateMixin, to simplify the coordination between user's form input data and the component's state.
  • classSet, for manipulating the DOM class string a bit more cleanly.
  • TestUtils, simple helpers for writing test cases (unminified build only).
  • cloneWithProps, to make shallow copies of React components and change their props.
  • update, a helper function that makes dealing with immutable data in JavaScript easier.

The add-ons below are in the development (unminified) version of React only:

  • PureRenderMixin, a performance booster under certain situations.
  • Perf, for measuring performance and giving you hint where to optimize.

To get the add-ons, use react-with-addons.js (and its minified counterpart) rather than the common react.js.

When using the react package from npm, just simply require('react/addons') instead of require('react') to get React with all of the addons.