You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I might be missing something but from reading the example and code these hooks don't actually allow you to render your data server side. Yes, you can render the state of your app before you have data and these hooks will allow you to wait for data being fetched serialized to the client. However in order to achieve SEO goals you have to have the data rendered within your html.
In graphql-hooks-ssr they make a pass through the app render tree with renderToStaticMarkup. That is what queues up the async requests. They then wait for those async requests to finish and then make another render pass with renderToString with your pre-loaded data.
The text was updated successfully, but these errors were encountered:
trainiac
changed the title
Doesn't wait for Data before rendering
Doesn't wait for data before rendering
Jun 8, 2019
I might be missing something but from reading the example and code these hooks don't actually allow you to render your data server side. Yes, you can render the state of your app before you have data and these hooks will allow you to wait for data being fetched serialized to the client. However in order to achieve SEO goals you have to have the data rendered within your html.
In
graphql-hooks-ssr
they make a pass through the app render tree withrenderToStaticMarkup
. That is what queues up the async requests. They then wait for those async requests to finish and then make another render pass withrenderToString
with your pre-loaded data.The text was updated successfully, but these errors were encountered: