MCPcopy Create free account
hub / github.com/microsoft/SandDance / throwOnInvalidObjectType

Function throwOnInvalidObjectType

docs/external/js/react-dom.development.js:13538–13552  ·  view source on GitHub ↗
(returnFiber, newChild)

Source from the content-addressed store, hash-verified

13536 }
13537
13538 function throwOnInvalidObjectType(returnFiber, newChild) {
13539 if (returnFiber.type !== 'textarea') {
13540 var addendum = '';
13541
13542 {
13543 addendum = ' If you meant to render a collection of children, use an array ' + 'instead.' + getCurrentFiberStackInDev();
13544 }
13545
13546 {
13547 {
13548 throw Error( "Objects are not valid as a React child (found: " + (Object.prototype.toString.call(newChild) === '[object Object]' ? 'object with keys {' + Object.keys(newChild).join(', ') + '}' : newChild) + ")." + addendum );
13549 }
13550 }
13551 }
13552 }
13553
13554 function warnOnFunctionType() {
13555 {

Callers 4

createChildFunction · 0.85
updateSlotFunction · 0.85
updateFromMapFunction · 0.85
reconcileChildFibersFunction · 0.85

Calls 1

Tested by

no test coverage detected