Follow up from #11616.
Here's one I found. These two invariants:
|
if (state && (typeof state !== 'object' || isArray(state))) { |
|
invariant( |
|
false, |
|
'%s.state: must be set to an object or null', |
|
getComponentName(workInProgress), |
|
); |
|
} |
|
if (typeof instance.getChildContext === 'function') { |
|
invariant( |
|
typeof workInProgress.type.childContextTypes === 'object', |
|
'%s.getChildContext(): childContextTypes must be defined in order to ' + |
|
'use getChildContext().', |
|
getComponentName(workInProgress), |
|
); |
are in a function that's behind a DEV block:
|
if (__DEV__) { |
|
checkClassInstance(workInProgress); |
|
} |
I don't think this is intentional, but need to verify.
There may be more. I'll use this issue to track while #11616 preserves existing behavior.