Skip to content

Commit e400b29

Browse files
Merge pull request #1154 from GetStream/v4.0.0-beta.7
fix: v4.0.0 beta.7
2 parents da1863d + 6c09276 commit e400b29

File tree

29 files changed

+7951
-11138
lines changed

29 files changed

+7951
-11138
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ This repo includes 4 example apps. One made with Expo, one Native JavaScript cod
4646

4747
- [Expo example](./examples/ExpoMessaging)
4848
- [Native example](./examples/NativeMessaging)
49-
- [Typescript example](./examples/TypescriptMessaging)
49+
- [Typescript example](./examples/TypeScriptMessaging)
5050
- [Fully featured messaging application](./examples/SampleApp)
5151

5252
Besides, our team maintains a dedicated repository for fully-fledged sample applications and demos at [GetStream/react-native-samples](https://github.com/GetStream/react-native-samples). Please consider checking following sample applications:

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

examples/NativeMessaging/yarn.lock

Lines changed: 1264 additions & 1387 deletions
Large diffs are not rendered by default.

examples/SampleApp/yarn.lock

Lines changed: 2031 additions & 2128 deletions
Large diffs are not rendered by default.

examples/TypeScriptMessaging/package.json

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,13 @@
5151
},
5252
"jest": {
5353
"preset": "react-native",
54-
"moduleFileExtensions": ["ts", "tsx", "js", "jsx", "json", "node"]
54+
"moduleFileExtensions": [
55+
"ts",
56+
"tsx",
57+
"js",
58+
"jsx",
59+
"json",
60+
"node"
61+
]
5562
}
5663
}

examples/TypeScriptMessaging/yarn.lock

Lines changed: 1297 additions & 1421 deletions
Large diffs are not rendered by default.

package/expo-package/yarn.lock

Lines changed: 630 additions & 701 deletions
Large diffs are not rendered by default.

package/native-package/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@
1616
"peerDependencies": {
1717
"@react-native-community/cameraroll": ">=4.0.1",
1818
"@react-native-community/netinfo": ">=2.0.7",
19+
"@stream-io/flat-list-mvcp": "0.10.1",
1920
"react-native": ">=0.60.0",
2021
"react-native-document-picker": ">=3.2.0",
2122
"react-native-fs": ">=2.16.6",
2223
"react-native-haptic-feedback": ">=1.11.0",
2324
"react-native-image-crop-picker": ">=0.33.2",
2425
"react-native-image-resizer": ">=1.4.2",
25-
"@stream-io/flat-list-mvcp": "0.10.1",
2626
"react-native-share": ">=4.1.0"
2727
},
2828
"scripts": {

package/native-package/yarn.lock

Lines changed: 638 additions & 709 deletions
Large diffs are not rendered by default.

package/package.json

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,20 +15,13 @@
1515
"module": "lib/module/index.js",
1616
"react-native": "src/index.ts",
1717
"types": "lib/typescript/index.d.ts",
18-
"files": [
19-
"src",
20-
"lib",
21-
"package.json",
22-
"README.md"
23-
],
18+
"files": ["src", "lib", "package.json", "README.md"],
2419
"scripts": {
2520
"analyze": "yarn build -- --stats && webpack-bundle-analyzer build/bundle-stats.json",
2621
"build": "rm -rf lib && yarn run --silent build-translations && bob build && yarn run --silent copy-translations && yarn run --silent lint-fix-translations",
2722
"lint-fix-translations": "prettier --check 'src/i18n/*.json' --write 'src/i18n/*.json' .eslintrc.json ../.prettierrc .babelrc",
2823
"build-translations": "rm -rf .tmpi18ncache || true && mkdir .tmpi18ncache && yarn run babel --config-file ./babel.i18next-extract.json 'src/**/*.{js,jsx,ts,tsx}' --out-dir '.tmpi18ncache/' && rm -rf .tmpi18ncache && prettier --write 'src/i18n/*.{js,ts,tsx,md,json}' .eslintrc.json ../.prettierrc .babelrc",
2924
"copy-translations": "echo '\u001b[34mℹ\u001b[0m Copying translation files to \u001b[34mlib/typescript/i18n\u001b[0m' && cp -R -f ./src/i18n ./lib/typescript/i18n && echo '\u001b[32m✓\u001b[0m Done Copying Translations'",
30-
"docs": "styleguidist build",
31-
"docs-server": "styleguidist server",
3225
"eslint": "eslint 'src/**/*.{js,md,ts,jsx,tsx}' --max-warnings 0",
3326
"lint": "prettier --ignore-path ../.prettierignore --list-different 'src/**/*.{js,ts,tsx,md,json}' .eslintrc.json ../.prettierrc .babelrc && eslint 'src/**/*.{js,ts,tsx,md}' --max-warnings 0 && yarn run validate-translations",
3427
"lint-fix": "prettier --ignore-path ../.prettierignore --write 'src/**/*.{js,ts,tsx,md,json}' .eslintrc.json ../.prettierrc .babelrc && eslint --fix 'src/**/*.{js,ts,tsx,md}' --max-warnings 0",
@@ -80,6 +73,7 @@
8073
"path": "0.12.7",
8174
"react-art": "^17.0.2",
8275
"react-native-markdown-package": "1.8.1",
76+
"react-native-url-polyfill": "^1.3.0",
8377
"stream-chat": "6.0.0"
8478
},
8579
"peerDependencies": {
@@ -138,10 +132,9 @@
138132
"react-native-svg": "12.1.1",
139133
"react-native-typescript-transformer": "1.2.13",
140134
"react-native-web": "0.15.0",
141-
"react-styleguidist": "11.1.6",
142135
"react-test-renderer": "17.0.2",
143136
"typescript": "4.4.3",
144137
"uuid": "8.3.2",
145138
"webpack": "4.44.2"
146139
}
147-
}
140+
}

0 commit comments

Comments
 (0)