()
| 12651 | } |
| 12652 | |
| 12653 | function createElementTypeChecker() { |
| 12654 | function validate(props, propName, componentName, location, propFullName) { |
| 12655 | if (!ReactElement.isValidElement(props[propName])) { |
| 12656 | var locationName = ReactPropTypeLocationNames[location]; |
| 12657 | return new Error('Invalid ' + locationName + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a single ReactElement.')); |
| 12658 | } |
| 12659 | return null; |
| 12660 | } |
| 12661 | return createChainableTypeChecker(validate); |
| 12662 | } |
| 12663 | |
| 12664 | function createInstanceTypeChecker(expectedClass) { |
| 12665 | function validate(props, propName, componentName, location, propFullName) { |
no test coverage detected
searching dependent graphs…