votrai123 / integrate-multiple-react-native

8 stars 4 forks source link

error when install react-native-animated in mini app. #7

Closed hookie256 closed 8 months ago

hookie256 commented 8 months ago

Describe the bug When I install react-native-animated in mini app, When from Parent app, I open Mini app, it appears blank screen and I found log [Reanimated] Native part of Reanimated doesn't seem to be initialized. See https://docs.swmansion.com/react-native-reanimated/docs/guides/troubleshooting#native-part-of-reanimated-doesnt-seem-to-be-initialized for more details. 2023-12-20 14:47:04.675533+0700 SuperApp[10491:115272] [javascript] TypeError: undefined is not an object (evaluating 'r(d[4]).AnimatedView')

votrai123 commented 8 months ago

Help me to detail the error correctly. (code, images, or steps ...) @hookie256

hookie256 commented 8 months ago

Step 1: from Mini app, I install react-native-animated lib by this instruction: https://docs.swmansion.com/react-native-reanimated/docs/fundamentals/getting-started/ Step 2: I run this command to export bundle file again: npx react-native bundle --platform ios --dev false --entry-file index.js --bundle-output ../../ios/index.ios-1.bundle --assets-dest ../../ios/ --reset-cache Step 3: I run yarn ios in Super App The SuperApp runs, after that I click to MiniApp One button, and MiniApp One open, the blank screen appear, and I see this error in Xcode log [Reanimated] Native part of Reanimated doesn't seem to be initialized. See https://docs.swmansion.com/react-native-reanimated/docs/guides/troubleshooting#native-part-of-reanimated-doesnt-seem-to-be-initialized for more details. 2023-12-20 14:47:04.675533+0700 SuperApp[10491:115272] [javascript] TypeError: undefined is not an object (evaluating 'r(d[4]).AnimatedView')

hookie256 commented 8 months ago

https://github.com/votrai123/integrate-multiple-react-native/assets/60592878/9a2869e6-478f-4a87-91cc-b2b53a277600 Screenshot 2023-12-20 at 15 13 37

votrai123 commented 8 months ago

3 #1

https://github.com/votrai123/integrate-multiple-react-native/issues/1#issuecomment-1801081984 It's the same as other issues @hookie256

hookie256 commented 8 months ago

Sorry, I missed some infomation, SuperApp I install react native version 0.69 MiniApp I install react native version 0.71 I resolve error by your above comment, but this error appears Screenshot 2023-12-20 at 15 44 24

hookie256 commented 8 months ago

So,Do MiniApp and SuperApp need the same react native version?

votrai123 commented 8 months ago

You can use

https://react-native-community.github.io/upgrade-helper/?from=0.69.0&to=0.71.0