Skip to content

Commit 5801f29

Browse files
Merge pull request #1120 from GetStream/khushal87-crns-472-1
docs: Channel delete blank screen troubleshooting docs [CRNS - 472]
2 parents 1d8f8db + 8d0eda6 commit 5801f29

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

docusaurus/docs/reactnative/basics/troubleshooting.mdx

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,17 @@ dependencies {
246246
}
247247
```
248248

249+
## Blank screen when channel gets delete
250+
251+
When a channel is deleted, and if some user is active on that channel, a blank screen appears by default (as per the default logic) as we return `null` in this case. It might be confusing for end user to see a blank screen and appropriate UX would be to navigate back to channel list screen. You can implement such UX by listening to `channel.deleted` event on channel screen, and navigate to channel list screen with appropriate notification on app.
252+
253+
````tsx
254+
client.on('channel.deleted', (event) => {
255+
if (event.cid === channel.cid) {
256+
// add your action here
257+
}
258+
}),
259+
249260
## Touchables not working
250261

251262
If you are having trouble with pressing, swiping, or otherwise interacting with components it is likely the result of [React Native Gesture Handler](https://docs.swmansion.com/react-native-gesture-handler/docs/) not being properly setup.
@@ -255,7 +266,7 @@ This includes ensuring you import `react-native-gesture-handler` at the top of y
255266

256267
```tsx
257268
import 'react-native-gesture-handler';
258-
```
269+
````
259270

260271
And for Android you additionally need to update `MainActivity.java` to override the method for creating the `ReactRootView`.
261272

0 commit comments

Comments
 (0)