Skip to content
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

Update setActive occurrences to state that org slug is accepted #1328

Merged
merged 3 commits into from
Aug 1, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/references/javascript/clerk/session-methods.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ function setActive({
| Name | Type | Description |
| - | - | - |
| `session?` | [`Session`](/docs/references/javascript/session) \| `string` \| `null` | The session resource or session ID (string version) to be set as active. If `null`, the current session is deleted. |
| `organization?` | [`Organization`](/docs/references/javascript/organization/organization) \| `string` \| `null` | The organization resource or organization ID (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `organization?` | [`Organization`](/docs/references/javascript/organization/organization) \| `string` \| `null` | The organization resource or organization ID/slug (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `beforeEmit?` | `(session?: Session \| null) => void \| Promise<any>` | Callback run just before the active session and/or organization is set to the passed object. Can be used to hook up for pre-navigation actions. |

### Example
Expand Down
2 changes: 1 addition & 1 deletion docs/references/react/use-organization-list.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ type OrganizationSuggestionStatus = "pending" | "accepted";
| Name | Type | Description |
| - | - | - |
| `session` | <code>[Session](/docs/references/javascript/session) \| string \| null</code> | The session resource or session ID (string version) to be set as active. If `null`, the current session is deleted. |
| `organization` | <code>[Organization](/docs/references/javascript/organization/organization) \| string \| null</code> | The organization resource or organization ID (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `organization` | <code>[Organization](/docs/references/javascript/organization/organization) \| string \| null</code> | The organization resource or organization ID/slug (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `beforeEmit?` | `(session?: Session \| null) => void \| Promise<any>` | Callback run just before the active session and/or organization is set to the passed object. Can be used to hook up for pre-navigation actions. |

### `PaginatedResources`
Expand Down
2 changes: 1 addition & 1 deletion docs/references/react/use-session-list.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ The `useSessionList()` hook returns an array of [`Session`](/docs/references/jav
| Name | Type | Description |
| - | - | - |
| `session` | <code>[Session](/docs/references/javascript/session) \| string \| null</code> | The session resource or session ID (string version) to be set as active. If `null`, the current session is deleted. |
| `organization` | <code>[Organization](/docs/references/javascript/organization/organization) \| string \| null</code> | The organization resource or organization ID (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `organization` | <code>[Organization](/docs/references/javascript/organization/organization) \| string \| null</code> | The organization resource or organization ID/slug (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `beforeEmit?` | `(session?: Session \| null) => void \| Promise<any>` | Callback run just before the active session and/or organization is set to the passed object. Can be used to hook up for pre-navigation actions. |

## How to use the `useSessionList()` hook
Expand Down
2 changes: 1 addition & 1 deletion docs/references/react/use-sign-in.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ The `useSignIn()` hook provides access to the [`SignIn`](/docs/references/javasc
| Name | Type | Description |
| - | - | - |
| `session` | <code>[Session](/docs/references/javascript/session) \| string \| null</code> | The session resource or session ID (string version) to be set as active. If `null`, the current session is deleted. |
| `organization` | <code>[Organization](/docs/references/javascript/organization/organization) \| string \| null</code> | The organization resource or organization ID (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `organization` | <code>[Organization](/docs/references/javascript/organization/organization) \| string \| null</code> | The organization resource or organization ID/slug (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `beforeEmit?` | `(session?: Session \| null) => void \| Promise<any>` | Callback run just before the active session and/or organization is set to the passed object. Can be used to hook up for pre-navigation actions. |

## How to use the `useSignIn()` hook
Expand Down
2 changes: 1 addition & 1 deletion docs/references/react/use-sign-up.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ The `useSignUp()` hook gives you access to the [`SignUp`](/docs/references/javas
| Name | Type | Description |
| - | - | - |
| `session` | <code>[Session](/docs/references/javascript/session) \| string \| null</code> | The session resource or session ID (string version) to be set as active. If `null`, the current session is deleted. |
| `organization` | <code>[Organization](/docs/references/javascript/organization/organization) \| string \| null</code> | The organization resource or organization ID (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `organization` | <code>[Organization](/docs/references/javascript/organization/organization) \| string \| null</code> | The organization resource or organization ID/slug (string version) to be set as active in the current session. If `null`, the currently active organization is removed as active. |
| `beforeEmit?` | `(session?: Session \| null) => void \| Promise<any>` | Callback run just before the active session and/or organization is set to the passed object. Can be used to hook up for pre-navigation actions. |

## How to use the `useSignUp()` hook
Expand Down
Loading