Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

hydrateRoot

Same as createRoot(), but is used to hydrate a container whose HTML contents were rendered by ReactDOMServer.

React will attempt to attach event listeners to the existing markup.

Example Usage

hydrateRoot(document.querySelector('#root'), <App />)
function hydrateRoot(
container: Element | Document,
initialChildren: React.ReactNode,
options?: HydrationOptions,
): Root;
§
hydrateRoot(container: Element | Document, initialChildren: React.ReactNode, options?: HydrationOptions): Root
[src]

§Parameters

§
container: Element | Document
[src]
§
initialChildren: React.ReactNode
[src]
§
options?: HydrationOptions optional
[src]

§Return Type