From b87c74d544f2c5434d0512dafd5d5cbb4f47c87b Mon Sep 17 00:00:00 2001 From: David Dal Busco Date: Thu, 4 Sep 2025 07:39:44 +0200 Subject: [PATCH 1/2] docs: window.location.reload on signOut Signed-off-by: David Dal Busco --- docs/build/authentication/development.md | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/docs/build/authentication/development.md b/docs/build/authentication/development.md index bd1c3276..99674ec1 100644 --- a/docs/build/authentication/development.md +++ b/docs/build/authentication/development.md @@ -57,7 +57,7 @@ try { ## Sign-out -You can end a user's session by logging them out. +You can end a user's session, no matter which provider they used to sign in, by logging them out. ```typescript import { signOut } from "@junobuild/core"; @@ -65,11 +65,15 @@ import { signOut } from "@junobuild/core"; await signOut(); ``` -:::note +By default, the page will automatically reload after a successful sign-out. This is a common pattern in logout flows that ensures the application restarts from a clean state. -This will clear the sign-in information stored in IndexedDB. +If you wish to opt out, the library does clear its internal state and authentication before the reload, and you can use the `windowReload` option set to `false`. -::: +```typescript +import { signOut } from "@junobuild/core"; + +await signOut({ windowReload: false }); +``` --- From 5832584993fa1deecfe5f7898d522db262e26fd3 Mon Sep 17 00:00:00 2001 From: github-actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 4 Sep 2025 05:41:18 +0000 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=93=84=20Update=20LLMs.txt=20snapshot?= =?UTF-8?q?=20for=20PR=20review?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .llms-snapshots/llms-full.txt | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/.llms-snapshots/llms-full.txt b/.llms-snapshots/llms-full.txt index 6bc09120..97db171f 100644 --- a/.llms-snapshots/llms-full.txt +++ b/.llms-snapshots/llms-full.txt @@ -854,15 +854,19 @@ import { signIn } from "@junobuild/core";try { await signIn();} catch (error: u ## Sign-out -You can end a user's session by logging them out. +You can end a user's session, no matter which provider they used to sign in, by logging them out. ``` import { signOut } from "@junobuild/core";await signOut(); ``` -**Note:** +By default, the page will automatically reload after a successful sign-out. This is a common pattern in logout flows that ensures the application restarts from a clean state. + +If you wish to opt out, the library does clear its internal state and authentication before the reload, and you can use the `windowReload` option set to `false`. -This will clear the sign-in information stored in IndexedDB. +``` +import { signOut } from "@junobuild/core";await signOut({ windowReload: false }); +``` ---