Skip to content

Commit ddf0d8c

Browse files
committed
Add snippet to changeset
1 parent 5bdffaf commit ddf0d8c

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

Diff for: .changeset/red-ducks-hide.md

+28
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,31 @@
55
---
66

77
Introduce `treatPendingAsSignedOut` prop to client control components
8+
9+
```tsx
10+
// Children node only mounts when session is active
11+
// Example: Organization selection must be completed if enforced
12+
<SignedIn>
13+
<p>You have selected an organization!</p>
14+
</SignedIn>
15+
```
16+
```tsx
17+
// Children node mounts for both active and pending session
18+
<SignedIn treatPendingAsSignedOut={false}>
19+
<p>You might not have an organization selected</p>
20+
</SignedIn>
21+
```
22+
23+
```tsx
24+
// Children node only mounts when session is active
25+
// Example: Organization selection must be completed if enforced
26+
<Protect>
27+
<p>You have selected an organization!</p>
28+
</Protect>
29+
```
30+
```tsx
31+
// Children node mounts for both active and pending session
32+
<Protect treatPendingAsSignedOut={false}>
33+
<p>You might not have an organization selected</p>
34+
</Protect>
35+
```

0 commit comments

Comments
 (0)