From 5aee237f112d28642fe4c79389a985fef0460cbc Mon Sep 17 00:00:00 2001 From: littensy <56808540+littensy@users.noreply.github.com> Date: Tue, 17 Feb 2026 18:46:30 -0800 Subject: [PATCH] docs: move listen nesting note --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index bc304b5..8824d86 100644 --- a/README.md +++ b/README.md @@ -332,6 +332,8 @@ end) setCounter(1) -- Count is 1 (was 0) ``` +Note that nested effects can be created inside `listen`, and they will clean up automatically when the listener re-runs or gets disposed. + ### Getter functions Reaction APIs like `listen()`, `subscribe()`, and `observe()` aren't only restricted to signals. You can listen to "getter" functions that call one or more signals, and they will automatically be memoized: @@ -352,8 +354,6 @@ setCounter(0.5) -- Doesn't print anything, floor is still 0 setCounter(1) -- Floor of count is 1 (was 0) ``` -Note that nested effects can be created inside `listen`, and they will clean up automatically when the listener re-runs or gets disposed. - --- ### `observe(getter, callback)`