Cannot make this work with Expo 45
See original GitHub issueIs there an existing issue for this?
- I have searched the existing issues
Workaround
https://github.com/nandorojo/moti/issues/199#issuecomment-1134805495
Current Behavior
I’ve started upgrading to expo 45
- Moti 0.17.1 and below fail because they rely on a feature in react-native-reanimated (reanimated2) that was remove (see https://github.com/software-mansion/react-native-reanimated/pull/3143).
- Moti 0.18.0 no longer fails on the issue listed for 0.17.1 but complains about
framer-motion
.
Now, I assume that the framer-motion issue is actually upstream / has to do with how webpack is importing the dependency, but I couldn’t find in the instructions how to make this work. Perhaps you have some guidance?
./node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs 34:2-10
Can't import the named export 'Children' from non EcmaScript module (only default export is available)
./node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs 74:31-45
Can't import the named export 'Fragment' from non EcmaScript module (only default export is available)
./node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs 144:29-43
[... many more ...]
Expected Behavior
It works without these errors
Steps To Reproduce
npx create-react-native-app -t with-moti
yarn add expo-cli -D
yarn expo upgrade
Y
(proceed)Y
(upgrade to 45.0.0)- Upgrade moti to
0.17.1
yarn install
yarn web
(it doesn’t work)- Upgrade moti to
0.18.0
yarn install
yarn web
(it doesn’t work)
Versions
- Moti: 0.18.0
- Reanimated: 2.8.0
- React Native: 0.68.2
Screenshots
No response
Reproduction
Issue Analytics
- State:
- Created a year ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Expo 45 build fail on Android with EAS
Hi All,. I've upgraded the SDK version to 45 recently. Everything works well except it doesn't build either on Android or IO. However ......
Read more >SDK 45 android can not build with eas build #19409 - GitHub
Do you have any idea to fix it? Execution failed for task ':app:bundleReleaseJsAndAssets_SentryUpload https://expo.dev/accounts/playmore/ ...
Read more >Update Expo SDK from 44 to 45, 46 or 47 not working
I tryed several times to update the SDK Version in my project from 44 to 45,46 and 47. Each time I try to...
Read more >expo-cli - npm
The command-line tool for creating and publishing Expo apps. Latest version: 6.0.8, last published: 2 months ago. Start using expo-cli in ...
Read more >Being free from “expo” in React Native apps - Medium
Expo allows you to work using an SDK with access to native functionalities easily saving your time whether you desire to create an...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
no, I think it’s just an issue with expo’s webpack config or something
does this help?
webpack.config.js
I got the idea to alias the imports from here: https://stackoverflow.com/a/70387589/7869175
@nandorojo yes.
I had to
rm -rf .expo/web
after doing a freshnode_modules
, but it then worked.