-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is ssrMode: true
in ApolloClient not needed when using SSR in client components?
#350
Comments
It's not needed at all: |
I have a different question, i just got done setting up a new project using makeClient code etc, but in my browser inspector i can see the browser making requests to the graphql server directly, shouldn't the requests be from the server to graphql server? |
SSR of Client Components only happens on initial page load. Every request you start after that is purely in the browser. |
I think this should be a bit more clear in the docs or readme, that every request after that happens in the browser. |
That's how Next.js works, that has nothing to do with this library. Next.js executes RSC on the server and does a single SSR pass of Client Components on page load, but after that executes Client Components purely in the browser. |
Do you have any feedback for the maintainers? Please tell us by taking a one-minute survey. Your responses will help us understand Apollo Client usage and allow us to serve you better. |
In the readme under In Client Components and streaming SSR section this following code is provided
Inside here:
is
ssrMode: true,
necessary here or is it handled internally by @apollo/experimental-nextjs-app-support where we imported it from?The text was updated successfully, but these errors were encountered: