[]previous and next page

createRegion

Creates the state of a region in parent.

Creates the state of a region in parent. anchorNode (null to append) and initial (nodes already in the DOM, from hydration or splitText) are both optional.

Import#

ts
import { createRegion } from "@shadow-js/web/extend";

Signature#

ts
function createRegion(parent: Node, anchorNode: Node | null, initial: unknown): Region