fetching data in component gives me the error Module not found: Can't resolve 'fs/promises'.
Unanswered
Northeast Congo Lion posted this in #help-forum
Northeast Congo LionOP
it works fine when i am in the "page" directory, but when i try to fetch in a component it gives me issues.
3 Replies
Northeast Congo LionOP
hmm i think the issue is that a parent component is a client component
but then how would i deal with that? a few levels above i need some javascript, so everything below cant be a server compnent anymore?
Siberian Flycatcher
You can do this
function Page() {
return (
<ClientComponent>
<ServerComponent />
</ClientComponent>
)
}