From 6a0097cf3811c471d474f69d54c45ea864d54f01 Mon Sep 17 00:00:00 2001 From: David Agustin <30575095+davidagustin@users.noreply.github.com> Date: Mon, 2 Nov 2020 16:37:02 -0800 Subject: [PATCH] Update Throw Error Message (#86) Co-authored-by: David Agustin --- src/components/inline/Button/Button.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/inline/Button/Button.js b/src/components/inline/Button/Button.js index a5ef1a9e..e74d6f2b 100644 --- a/src/components/inline/Button/Button.js +++ b/src/components/inline/Button/Button.js @@ -37,7 +37,9 @@ const Button = ({ text, externalLink, internalLink, onClick }) => { ); } - throw new Error("PropTypes are invalid"); + throw new Error( + "Missing required prop. Must specify one of: externalLink, internalLink, or onClick." + ); }; Button.propTypes = PropTypes.oneOfType([