-
Notifications
You must be signed in to change notification settings - Fork 402
feat(clerk-js): Handle new session pending status as authenticated state
#5136
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(clerk-js): Handle new session pending status as authenticated state
#5136
Conversation
🦋 Changeset detectedLatest commit: e69c175 The changes in this PR will be included in the next version bump. This PR includes changesets to release 23 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
pending session status as authenticated userpending status
4b907c1 to
cdee2c9
Compare
cdee2c9 to
a9143d3
Compare
a9143d3 to
f21d6e7
Compare
f21d6e7 to
b3044d2
Compare
b3044d2 to
96a7629
Compare
96a7629 to
f249b85
Compare
f249b85 to
37f3c34
Compare
37f3c34 to
f51ee21
Compare
bb1b736 to
760434f
Compare
cd69f17 to
42d5e5f
Compare
d05cb1b to
724a3fa
Compare
724a3fa to
de92ffd
Compare
de92ffd to
e69c175
Compare
|
Hello! Sorry if this is the wrong place to ask but I wasn't able to get my discord account working. I begin getting type errors (error TS2322) when updating to version 4.47.0 of types. Is this expected and is it resolved by an update to the corresponding clerk packages? We are using |
Description
Context
Introducing a new FAPI session status:
pending. It builds a fundamental layer for the after-auth project and the future concept of tasks, eg: Forcing to select an organization after sign-in.Previously, only
activesessions were considered to be in an authenticated state. Now, we're introducing a new status assigned to the user session after a successful authentication process but when there are pending tasks.Next steps
These changes do not introduce new behavior on helpers / AIO components, neither breaking changes, as it handles
pendingas an authenticated state, pairing the same functionality asactiveNext PRs will start introducing the concept of pending tasks and enforcing resolution upon after-auth.
Developer-facing changes
Once these clerk-js get served, developers shouldn't have to worry about changing their app logic or breaking changes. However, some interface changes are preparing the DX for the next steps mentioned above:
Unifying an signed-in state check based on the session status with
Clerk.isSignedInorClerk.client.isSignedInFor custom flows,
Clerk.usershouldn't be used to determine if the user has fully authenticated or not, and also, it shouldn't be necessary for developers to explicitly check against the session as it's prone for breaking changes, therefore we're abstracting this behind a new property.Deprecating
activeSessionsin favor ofsignedInSessionsDeprecating explicit checks against "active" sessions in favor of a generic property that expresses the "signed-in" state instead, since in the future, we might add other types of session statuses for different levels of user verification as we're doing now with after-auth.
Checklist
pnpm testruns as expected.pnpm buildruns as expected.Type of change