aboutsummaryrefslogtreecommitdiff
path: root/src/example.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/example.ts')
-rw-r--r--src/example.ts16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/example.ts b/src/example.ts
index 229d3a0..0870f4e 100644
--- a/src/example.ts
+++ b/src/example.ts
@@ -185,9 +185,23 @@ const seq =
)
)
+const indirectCheckbox =
+ withState(false, checked => [
+ checkboxComponent({
+ label: 'C1',
+ isChecked: checked,
+ onCheck: (b: boolean) => checked.update(_ => b)
+ }),
+ checkboxComponent({
+ label: 'C2',
+ isChecked: checked,
+ onCheck: (b: boolean) => checked.update(_ => b)
+ })
+ ])
+
const view = h('main',
h('h1', 'Rx'),
- chrono
+ indirectCheckbox
)
mount(view)