You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Objects created with functions returned by React.createClass() are instanceof ReactCompositeComponentBase, but this constructor isn't exposed to end-users.
Adding it to React.__internals would enable this check for anyone who needs it.
Use case: creating a version of creationix/dombuilder which uses React.DOM functions instead of document.createElement() and need to detect objects which should be left as-is for React to deal with.
The text was updated successfully, but these errors were encountered:
I would really like to avoid adding anything to __internals and I would encourage you not to depend on that. That's basically there only to make the devtools work and I would like to kill it ASAP.
If @spicyj's suggestion doesn't work for you and you're doing this in node-land, you could require('react/lib/ReactCompositeComponent') directly. No guarantees on those APIs right now but it's there.
Objects created with functions returned by
React.createClass()
areinstanceof ReactCompositeComponentBase
, but this constructor isn't exposed to end-users.Adding it to
React.__internals
would enable this check for anyone who needs it.Use case: creating a version of creationix/dombuilder which uses
React.DOM
functions instead ofdocument.createElement()
and need to detect objects which should be left as-is for React to deal with.The text was updated successfully, but these errors were encountered: