Description
Here’s my outline of what I think we should do with addons in React 16.
TLDR: we’ve done a poor job of supporting them, and they pose a significant maintenance burden due to how our repo and build process is set up. We’re going to release final versions for them, and won’t be maintaining them further.
Plan: Don’t Do Anything
react-addons-perf
Internal dependencies (will break in 16):
react-dom/lib/ReactPerf
Plan for 15.5: don’t do anything.
Plan for 16: we won’t be releasing 16 for this package. Right now there is no migration path planned for it because Fiber works differently. Instead, you would use the browser Timeline integration (or polyfill it in your environment). We may later reintroduce something like ReactPerf
, but in the renderers themselves. However, just like it took us a while to figure out how ReactPerf
should work, it will take us a while to figure out a better alternative that would be compatible with Fiber.
Plan: Fix and Forget
react-addons-create-fragment
Internal dependencies (will break in 16):
react/lib/ReactFragment
Plan for 15.5: copy internal dependencies into the package to make sure it works standalone. Ensure there is a UMD build in the standalone package, and that it is documented in package's README. Make sure that accessing it via React.addons.createFragment
(but not via the package) warns once and suggests using UMD build instead. Release 15.5 without a peer dependency restriction on react
and forget about it forever.
Plan for 16: we won’t be releasing 16 for this package. Nevertheless version 15 should keep working indefinitely.
react-addons-linked-state-mixin
Internal dependencies (will break in 16):
react/lib/LinkedStateMixin
Plan for 15.5: copy internal dependencies into the package to make sure it works standalone. Ensure there is a UMD build in the standalone package, and that it is documented in package's README. Make sure that accessing it via React.addons.LinkedStateMixin
(but not via the package) warns once and suggests using UMD build instead. Release 15.5 without a peer dependency restriction on react
and forget about it forever.
Plan for 16: we won’t be releasing 16 for this package. Nevertheless version 15 should keep working indefinitely.
react-addons-pure-render-mixin
Internal dependencies (will break in 16):
react/lib/ReactComponentWithPureRenderMixin
Plan for 15.5: copy internal dependencies into the package to make sure it works standalone. Ensure there is a UMD build in the standalone package, and that it is documented in package's README. Make sure that accessing it via React.addons.PureRenderMixin
(but not via the package) warns once and suggests using UMD build instead. Release 15.5 without a peer dependency restriction on react
and forget about it forever.
Plan for 16: we won’t be releasing 16 for this package. Nevertheless version 15 should keep working indefinitely.
react-addons-shallow-compare
Internal dependencies (will break in 16):
react/lib/shallowCompare
Plan for 15.5: copy internal dependencies into the package to make sure it works standalone. Ensure there is a UMD build in the standalone package, and that it is documented in package's README. Make sure that accessing it via React.addons.shallowCompare
(but not via the package) warns once and suggests using UMD build instead. Release 15.5 without a peer dependency restriction on react
and forget about it forever.
Plan for 16: we won’t be releasing 16 for this package. Nevertheless version 15 should keep working indefinitely.
react-addons-update
Internal dependencies (will break in 16):
react/lib/update
Plan for 15.5: copy internal dependencies into the package to make sure it works standalone. Ensure there is a UMD build in the standalone package, and that it is documented in package's README. Make sure that accessing it via React.addons.update
(but not via the package) warns once and suggests using UMD build instead. Release 15.5 without a peer dependency restriction on react
and forget about it forever. In README, mention https://github.com/kolodny/immutability-helper as a more maintained alternative.
Plan for 16: we won’t be releasing 16 for this package. Nevertheless version 15 should keep working indefinitely.
react-linked-input
Internal dependencies (will break in 16):
react/lib/LinkedValueUtils
Plan for 15.5: copy internal dependencies into the package to make sure it works standalone. Release 15.5 without a peer dependency restriction on react
and forget about it forever. There is no extra step for React.addons
because it is not exposed there at all.
Plan for 16: we won’t be releasing 16 for this package. Nevertheless version 15 should keep working indefinitely.
Plan: Deprecate and Forget
react-addons-css-transition-group
Internal dependencies (will break in 16):
react/lib/ReactCSSTransitionGroup
Plan for 15.5: deprecate. We won’t maintain this further. Suggest using CSSTransitionGroup
from https://github.com/reactjs/react-transition-group instead. Work with its maintainers to ensure there’s an UMD build (and instructions for it in README).
Plan for 16: we won’t be releasing 16 for this package.
react-addons-transition-group
Internal dependencies (will break in 16):
react/lib/ReactTransitionGroup
Plan for 15.5: deprecate. We won’t maintain this further. Suggest using TransitionGroup
from https://github.com/reactjs/react-transition-group instead. Work with its maintainers to ensure there’s an UMD build (and instructions for it in README).
Plan for 16: we won’t be releasing 16 for this package.
Plan: Undecided
react-addons-test-utils
Internal dependencies (will break in 16):
react-dom/lib/ReactTestUtils
I don’t have a plan for this one yet. Technically it’s still going to be coupled to react-dom
package. TestUtils
is technically two completely different things: a thin wrapper around react-dom
with some introspection, and a shallow renderer. Perhaps it would make sense to completely move TestUtils
to react-dom
except shallow renderer which could be published as react-shallow-renderer
.