- What is the right time to do hydration?
- What is the right time to call API? I am using useLazyLoadQuery hook, seems the getInitialProps method is not the right choice.
I have tried the the example from nextjs, it is not usefull for me. In my situation, I have a Layout
Component would will make API request, for example, fetching menu data. the layout component will have sub component which would make API request too, so we can never anticipate what API would be called inside a sub component. that is we have no way to gather all API request into the getInitialProps
.