phamha98 / hi

note
Other
2 stars 0 forks source link

Remove Warning : [react-native-gesture-handler] Seems like you're using an old API with gesture components, check out new Gestures system #7

Open phamha98 opened 2 years ago

phamha98 commented 2 years ago

Remove Warning : [react-native-gesture-handler] Seems like you're using an old API with gesture components, check out new Gestures system

"dependencies": {
    "@react-navigation/native": "^6.0.6",
    "@react-navigation/stack": "^6.0.11",
    "@types/styled-components": "^5.1.20",
    "moment": "^2.29.1",
    "react": "17.0.2",
    "react-native": "0.66.4",
    "react-native-gesture-handler": "^2.2.0",
    "react-native-get-location": "^2.2.1",
    "react-native-linear-gradient": "^2.5.6",
    "react-native-reanimated": "^2.3.1",
    "react-native-safe-area-context": "^3.3.2",
    "react-native-screens": "^3.10.2",
    "styled-components": "^5.3.3"
  },
phamha98 commented 2 years ago

The new version, of react-native-gesture-handler send warning if you use an old API version, but also if one of your package/library use it.

To disable the warning, you can ignore logs.

in your app.js / app.tsx


import { LogBox } from 'react-native';

LogBox.ignoreLogs([
  "[react-native-gesture-handler] Seems like you\'re using an old API with gesture components, check out new Gestures system!",
]);
phamha98 commented 2 years ago

update

    "react-native-gesture-handler": "^1.10.3",
phamha98 commented 2 years ago

https://github.com/software-mansion/react-native-gesture-handler/issues/1831