GestureHandler is not defined in Expo 27.0.2

#1

Did the location of GestureHandler change (specifically PinchGestureHandler), or is this simply an error with the build? It works fine in 27.0.1.

import { GestureHandler } from ‘expo’;
const { PinchGestureHandler } = GestureHandler; //Cannot read property ‘PinchGestureHandler’ of undefined

0 Likes

#2

import { PinchGestureHandler } from GestureHandler;

this is wrong, it should be

const { PinchGestureHandler } = GestureHandler;

0 Likes

#3

Sorry I am actually using const { PinchGestureHandler } = GestureHandler;

I just copied it wrong in this post

0 Likes

#4

gotcha. fixed for sdk28 (to be released soon). for now import from react-native-gesture-handler directly: https://github.com/expo/expo/issues/1809

2 Likes

#5

ok thanks

0 Likes

closed #6

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.

0 Likes