Style componentes
Unanswered
American black bear posted this in #help-forum
![Avatar](https://cdn.discordapp.com/embed/avatars/0.png)
American black bearOP
is there a way to use styled of styled components in server side rendering ?
9 Replies
![Avatar](https://cdn.discordapp.com/embed/avatars/1.png)
Broad-snouted Caiman
![Avatar](https://cdn.discordapp.com/embed/avatars/0.png)
American black bearOP
i have implement that but when a use a componend that includes styled, it says that i have to use 'use client'
![Avatar](https://cdn.discordapp.com/embed/avatars/1.png)
Broad-snouted Caiman
what you have inside that component ?
![Avatar](https://cdn.discordapp.com/embed/avatars/0.png)
American black bearOP
jus a component that is using styled.div
Error: createContext only works in Client Components. Add the "use client" directive at the top of the file to use it. Read more: https://nextjs.org/docs/messages/context-in-server-component
![Avatar](https://cdn.discordapp.com/embed/avatars/5.png)
Shy Albatross
last time I checked, styled-components use contex for their provider, so anywhere you use them you have to make client comp, which sucks
![Avatar](https://cdn.discordapp.com/embed/avatars/4.png)
Somali
No way around this? Does this mean you can’t SSR with them?
![Avatar](https://cdn.discordapp.com/embed/avatars/5.png)
Great golden digger wasp
you can SSR but you cant use styled-components in RSC right now
![Avatar](https://cdn.discordapp.com/embed/avatars/0.png)
American black bearOP
is there a way to pass media queries as props to a compoennt? and if so i allows you to do in the server side ?