React type.toUpperCase is not a function

Kevin Simper
1 min readJun 30, 2015

--

If you get this error

type.toUpperCase is not a function

then you probrably forgot to use

module.exports = MyNewComponent

It can not be easy to spot, because the error does not show where it actually is, you see something like this

So before you pull your hair out (as I have done), go back and look at the latest component you made, and check if you export the module correct.

--

--

Kevin Simper
Kevin Simper

Written by Kevin Simper

I really like building stuff with React.js and Docker and also Meetups ❤