design-system icon indicating copy to clipboard operation
design-system copied to clipboard

Make theme-related errors more descriptive

Open craigpalermo opened this issue 4 years ago • 0 comments

Is your feature request related to a problem? Please describe. In many cases, when we see an error like Uncaught TypeError: Cannot read property '3' of undefined, the root cause is that a styled component can't access the theme. This could be for many reasons; the app doesn't have a theme provider, the app has imported multiple instances of styled-components, etc.

Describe the solution you'd like If an exception like this is thrown from within a styled component, we should hint at this being the cause.

craigpalermo avatar Jul 02 '20 20:07 craigpalermo