diff --git a/checkPropTypes.js b/checkPropTypes.js index 49111df..1ad29fe 100644 --- a/checkPropTypes.js +++ b/checkPropTypes.js @@ -53,7 +53,8 @@ function checkPropTypes(typeSpecs, values, location, componentName, getStack) { if (typeof typeSpecs[typeSpecName] !== 'function') { var err = Error( (componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' + - 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' + 'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' + + 'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.' ); err.name = 'Invariant Violation'; throw err;