From 9ccabbb627447c83d3a637d89901668b7e7f1cbe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julien=20Valverd=C3=A9?= Date: Sun, 11 May 2025 07:10:38 +0200 Subject: [PATCH] Tests --- packages/example/src/routes/tests.tsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/example/src/routes/tests.tsx b/packages/example/src/routes/tests.tsx index 0ffe0c1..ac58463 100644 --- a/packages/example/src/routes/tests.tsx +++ b/packages/example/src/routes/tests.tsx @@ -15,6 +15,7 @@ export const Route = createFileRoute("/tests")({ function RouteComponent() { const runSync = R.useRunSync() + const runPromise = R.useRunPromise() const [uuid, setUuid] = useState(R.useMemo(() => makeUuid, [])) const generateUuid = R.useCallbackSync(() => makeUuid.pipe( @@ -22,7 +23,7 @@ function RouteComponent() { ), []) const uuidStream = R.useStreamFromReactiveValues([uuid]) - const uuidStreamLatestValue = R.useSubscribeStream(uuidStream) + const [uuidStreamLatestValue, pullUuidStream] = R.usePullStream(uuidStream) const scope = R.useScope([uuid]) @@ -38,11 +39,11 @@ function RouteComponent() { {Option.match(uuidStreamLatestValue, { - onSome: v => v, + onSome: ([v]) => v, onNone: () => <>, })} - {/* */} + ) }