wodin / expo-ocr-example

MIT License
18 stars 2 forks source link

Getting following error as I hit recognise. Am I missing any step ? #1

Open krushal-kyada opened 3 years ago

krushal-kyada commented 3 years ago

null is not an object (evaluating '_reactNativeTesseractOcr.default.recognize') at App.js:68:35 in recognizeTextFromImage at App.js:63:33 in recognizeTextFromImage at App.js:93:36 in Button.props.onPress at node_modules/react-native/Libraries/Pressability/Pressability.js:691:17 in _performTransitionSideEffects at node_modules/react-native/Libraries/Pressability/Pressability.js:628:6 in _receiveSignal at node_modules/react-native/Libraries/Pressability/Pressability.js:524:8 in responderEventHandlers.onResponderRelease

epoq commented 3 years ago

hello , i have the same issue ===> null is not an object (evaluating '_reactNativeTesseractOcr.default.recognize')

wodin commented 2 years ago

Hi. Did you build with eas build?

react-native-tesseract-ocr depends on native code, so you need to build with eas build instead of expo build. Also, this won't work in Expo Go. You need to build a custom dev client (with eas build --profile development)