I\'m writing Jest tests for my React code and hoping to make use of/test the PropType checks. I am quite new to the Javascript universe. I\'m using npm to install reac
reac
A new package jest-prop-type-error is simple to add and fails on PropType errors:
PropType
Install via:
yarn add -D jest-prop-type-error
Then add the following to your package.json's setupFiles in the jest section:
package.json
setupFiles
jest
"setupFiles": [ "jest-prop-type-error" ]