Closed JimmyLv closed 7 years ago
@JimmyLv This is because styles
is a css-module (just an object) and header
is a string key with a string value of actual generated classname when theme
should be an object, not string. Just try <Header theme={styles}/>
.
Thanks, sorry for the incorrect usage.🐒
On Mar 22, 2017, 7:49 PM +0800, Kirill Agalakov notifications@github.com, wrote:
@JimmyLv (https://github.com/JimmyLv) This is because styles is a css-module (just an object) and header is a string key with a string value of actual generated classname when theme should be an object, not string. Just try
. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub (https://github.com/javivelasco/react-css-themr/issues/49#issuecomment-288375326), or mute the thread (https://github.com/notifications/unsubscribe-auth/AExBWscyihNLv8gukuPLkthAiRGDh5gkks5roQq5gaJpZM4MRO10).
Thanks @raveclassic
I love this idea, but I got this error when following the README.md doc:
Error happened when pass theme as prop in parent component: