Readme

Hono Island

See it in action at @pomdtr/hono_island_demo

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/** @jsxImportSource https://esm.sh/hono/jsx */
export function Island({
src,
name,
children,
}: {
src: string;
name: string;
children: any;
}) {
if (Array.isArray(children)) {
throw new Error("only a single children is supported in an Island component");
}
return (
<div
data-hydration-src={src}
data-hydration-name={name}
data-hydration-props={JSON.stringify(children.props)}
>
{children}
</div>
);
}
Val Town is a social website to write and deploy JavaScript.
Build APIs and schedule functions from your browser.
Comments
Nobody has commented on this val yet: be the first!
v11
March 17, 2024