#Are you guys using server components in production ?

17 messages · Page 1 of 1 (latest)

cold swallow
#

I had some questions regarding server components like

  1. is is good idea to use server components for search results and tables do you see changes over client components.
hard coralBOT
#

🔎 This post has been indexed in our web forum and will be seen by search engines so other users can find it outside Discord

🕵️ Your user profile is private by default and won't be visible to users outside Discord, if you want to be visible in the web forum you can add the "Public Profile" role in id:customize

✅ You can mark a message as the answer for your post with Right click -> Apps -> Mark Solution
(if you don't see the option, try refreshing Discord with Ctrl + R)

half musk
cold swallow
half musk
cold swallow
#

used to display heave components, like: tables with pagination,
maps, secondary frames etc..

very useful when need to increase webiste performance

#

but be careful with it

#

@cold swallow

#

@cold swallow what are things I should be card

cold swallow
silver meadow
cold swallow
#

yep

half musk
#

@cold swallowsolved?

acoustic zephyr
daring crypt
# acoustic zephyr 2). point is not always true. The client components won't always be server rende...

client components are, in fact, server side rendered. @/Clown was right. see also: Why do Client Components get SSR'd to HTML? by Dan Abramov, former? member of the React team.

useContext is prerendered on the server using the initial value of the context.

useState is also prerendered, using the initial value of the state.

using browser APIs requires useEffect.

useEffect is not prerendered because it only runs after the first browser rendering is finished.

GitHub

If you're familiar with React, your mental model before RSC might look similar to this (blank space on the left is intentional): RSC does not change that mental model, but it adds a new layer b...

acoustic zephyr
daring crypt
# acoustic zephyr <@484037068239142956> So Why don't I see the Raw HTML Data in View Source if I'...

your code bug, possibly. without seeing your code i can't guess.

if you want it debugged, i suggest opening a new #1007476603422527558 post where people can come see why your component is not being server rendered.

in the meantime i will give you this:
https://github.com/joulev/debug/blob/nextjs-client-component-ssr-example/app/client-components.tsx
https://debug-git-nextjs-client-component-ssr-example-joulev-proj.vercel.app