sdk/client
The rwsdk/client
module provides a set of functions for client-side operations.
initClient
The initClient
function is used to initialize the React Client. This hydrates the RSC flight payload that’s add at the bottom of the page. This makes the page interactive.
initClientNavigation
The initClientNavigation
function is used to initialize the client side navigation. An event handler is assocated to clicking the document. If the clicked element contains a link, href, and the href is a relative path, the event handler will be triggered. This will then fetch the RSC payload for the new page, and hydrate it on the client.