Skip to content

Commit 9b0367f

Browse files
authored
feat: remove usage of flatlist-mvcp in favour of mvcp support in RN >= 0.72 (#2539)
* fix: add expo-clipboard to peer deps of expo-package (#2537) * feat: remove usage of flatlist-mvcp in favour of mvcp support in RN >= 0.72 * fix: remove flatlist-mvcp from example apps * chore: update peer dep of react native
1 parent 1ce7e8e commit 9b0367f

File tree

15 files changed

+1159
-1415
lines changed

15 files changed

+1159
-1415
lines changed

docusaurus/docs/reactnative/customization/native-handlers.mdx

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -62,14 +62,6 @@ A function that deletes a file at a given local `uri`.
6262
| ---------------------------------------------------------------- | -------------------------------------------------------------------------- |
6363
| [`react-native-fs`](https://github.com/itinance/react-native-fs) | [`expo-file-system`](https://docs.expo.io/versions/latest/sdk/filesystem/) |
6464

65-
### `FlatList`
66-
67-
A FlatList component, on Expo the standard React Native component is used, on React Native a modified FlatList better fit for two directional scrolling is used.
68-
69-
| React Native CLI | Expo |
70-
| -------------------------------------------------------------------------- | ------------------------------------------------------- |
71-
| [`@stream-io/flat-list-mvcp`](https://github.com/GetStream/flat-list-mvcp) | [`react-native`](https://reactnative.dev/docs/flatlist) |
72-
7365
### `getLocalAssetUri`
7466

7567
A function that gets the local `uri` of an image or remote asset.

examples/SampleApp/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333
"@react-navigation/drawer": "6.6.9",
3434
"@react-navigation/native": "^6.1.12",
3535
"@react-navigation/stack": "^6.3.0",
36-
"@stream-io/flat-list-mvcp": "0.10.3",
3736
"react": "18.2.0",
3837
"react-native": "^0.73.0",
3938
"react-native-audio-recorder-player": "^3.6.7",

examples/SampleApp/yarn.lock

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2061,11 +2061,6 @@
20612061
dependencies:
20622062
"@sinonjs/commons" "^3.0.0"
20632063

2064-
"@stream-io/[email protected]":
2065-
version "0.10.3"
2066-
resolved "https://registry.yarnpkg.com/@stream-io/flat-list-mvcp/-/flat-list-mvcp-0.10.3.tgz#774e56aba7f3da5a8f2ae5ad3065f05e5a27e7f2"
2067-
integrity sha512-2ZK8piYlEfKIPZrH8BpZz9uj8HZcUvMCV0X7qSLSAc/vhLOANBfR0SSn0OaWPbqb2mFGAd4FxmLSPp1zKEYuaw==
2068-
20692064
"@types/babel__core@^7.1.14":
20702065
version "7.20.5"
20712066
resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.20.5.tgz#3df15f27ba85319caa07ba08d0721889bb39c017"

examples/TypeScriptMessaging/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
"@react-native-community/netinfo": "^11.3.2",
1919
"@react-navigation/native": "^6.0.8",
2020
"@react-navigation/stack": "^6.2.0",
21-
"@stream-io/flat-list-mvcp": "0.10.3",
2221
"react": "18.2.0",
2322
"react-native": "^0.73.6",
2423
"react-native-audio-recorder-player": "3.6.6",

examples/TypeScriptMessaging/yarn.lock

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2364,11 +2364,6 @@
23642364
dependencies:
23652365
"@sinonjs/commons" "^3.0.0"
23662366

2367-
"@stream-io/[email protected]":
2368-
version "0.10.3"
2369-
resolved "https://registry.yarnpkg.com/@stream-io/flat-list-mvcp/-/flat-list-mvcp-0.10.3.tgz#774e56aba7f3da5a8f2ae5ad3065f05e5a27e7f2"
2370-
integrity sha512-2ZK8piYlEfKIPZrH8BpZz9uj8HZcUvMCV0X7qSLSAc/vhLOANBfR0SSn0OaWPbqb2mFGAd4FxmLSPp1zKEYuaw==
2371-
23722367
"@types/babel__core@^7.1.14":
23732368
version "7.20.1"
23742369
resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.20.1.tgz#916ecea274b0c776fec721e333e55762d3a9614b"

package/expo-package/src/index.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
import { FlatList } from 'react-native';
2-
31
import { registerNativeHandlers } from 'stream-chat-react-native-core';
42

53
import {
@@ -27,7 +25,6 @@ registerNativeHandlers({
2725
Audio,
2826
compressImage,
2927
deleteFile,
30-
FlatList,
3128
getLocalAssetUri,
3229
getPhotos,
3330
iOS14RefreshGallerySelection,

package/jest-setup.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/* global require */
2-
import { FlatList, View } from 'react-native';
2+
import { View } from 'react-native';
33

44
import mockRNCNetInfo from '@react-native-community/netinfo/jest/netinfo-mock.js';
55

@@ -16,7 +16,6 @@ registerNativeHandlers({
1616
},
1717
compressImage: () => null,
1818
deleteFile: () => null,
19-
FlatList,
2019
getLocalAssetUri: () => null,
2120
getPhotos: () => null,
2221
oniOS14GalleryLibrarySelectionChange: () => ({

package/native-package/package.json

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@
1616
"peerDependencies": {
1717
"@react-native-camera-roll/camera-roll": ">=5.0.0",
1818
"@react-native-clipboard/clipboard": "^1.11.1",
19-
"@stream-io/flat-list-mvcp": "^0.10.3",
20-
"react-native": ">=0.60.0",
19+
"react-native": ">=0.73.6",
2120
"react-native-document-picker": ">=9.0.1",
2221
"react-native-fs": ">=2.16.6",
2322
"react-native-haptic-feedback": ">=1.11.0",
@@ -53,8 +52,7 @@
5352
},
5453
"devDependencies": {
5554
"@react-native-camera-roll/camera-roll": "^5.0.2",
56-
"@stream-io/flat-list-mvcp": "0.10.3",
57-
"react-native": ">=0.60.0",
55+
"react-native": ">=0.73.6",
5856
"react-native-fs": ">=2.16.6",
5957
"react-native-image-crop-picker": "^0.38.0",
6058
"react-native-image-resizer": ">=1.4.2"

package/native-package/src/index.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import { Platform } from 'react-native';
22

3-
import { FlatList } from '@stream-io/flat-list-mvcp';
43
import { registerNativeHandlers } from 'stream-chat-react-native-core';
54

65
import {
@@ -28,7 +27,6 @@ registerNativeHandlers({
2827
Audio,
2928
compressImage,
3029
deleteFile,
31-
FlatList,
3230
getLocalAssetUri,
3331
getPhotos,
3432
iOS14RefreshGallerySelection,

0 commit comments

Comments
 (0)