From bce472ab375af1a22d3be27452c38604782c9c72 Mon Sep 17 00:00:00 2001 From: MapleLeaf <19603573+itsMapleLeaf@users.noreply.github.com> Date: Sat, 25 Dec 2021 03:54:35 -0600 Subject: [PATCH] embed children --- playground/counter.tsx | 15 ++++----- src.new/container.ts | 27 +++++++++++++++ src.new/element.tsx | 11 +++++++ src.new/embed.tsx | 74 +++++++++++++++++++++++++++++++++++++----- src.new/node.ts | 2 ++ src.new/reconciler.ts | 22 ++++++++++--- src.new/renderer.ts | 23 ++----------- 7 files changed, 130 insertions(+), 44 deletions(-) create mode 100644 src.new/container.ts create mode 100644 src.new/element.tsx diff --git a/playground/counter.tsx b/playground/counter.tsx index 1925c19..6bbd235 100644 --- a/playground/counter.tsx +++ b/playground/counter.tsx @@ -10,15 +10,12 @@ export function Counter() { <> this button was clicked {count} times {embedVisible && ( - + + the counter + + {count % 2 === 0 ? "yes" : "no"} + + )} {embedVisible && (