Clears a lot of doubts and provides much more of what's going on in-depth as compared to normal blog articles comparing different rendering strategies.
Could please explain why we can render server components inside client components? Because the main concept of Nextjs, how i understand, is to put client component as much as you can deep inside server. So the question is, how it works, and how to use redux providers, context and etc. Thanks @@CodeWithAhsan
If all the functions in next js are server side by default then why do we need to add the use server directive on top in the server action function ? Is it because we are calling it in a client component?
Yeah, as I explained in the video. Server Actions are the ones called inside the client components after the page has been rendered in the browser (CSR is finished)
so even if the component is server side rendered , we still need js enabled to execute that content when it comes back from server and this is called as hydration right..?
Not necessarily always. If you have a server-side component that doesn’t send a loading screen in nextjs, then you don’t need client side render for “rendering “ but rather for binding events and using hooks etc. But if your server sends a loading screen in nextjs, you need client side js to swap the content after the backend sort of streams the rendered content once loading is done. So are correct 👍🏼 I just explained in a more specific way