Is there a way to pass in data fetched from RSC into context?
Answered
Bengal posted this in #help-forum
BengalOP
^
I have a server component that fetches data. I'd like to share it in a context with Client components, but you can't really pass in that data can you?
I have a server component that fetches data. I'd like to share it in a context with Client components, but you can't really pass in that data can you?
Answered by Madeiran sardinella
Yes, you can pass props from server component to the context provider.
2 Replies
Madeiran sardinella
Yes, you can pass props from server component to the context provider.
Answer
BengalOP
yeah realised haha ty