Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork1.8k
Open
Description
Description
If I use an external uri Eg. website link or online asset it plays fine. So there is no issue from the .lottie file itself.
JSON files load well from the device usingrequire()
Only .lottie files have a problem:
Here is my metro:
// Learn more https://docs.expo.io/guides/customizing-metroconst { getDefaultConfig } = require('expo/metro-config');/** @type {import('expo/metro-config').MetroConfig} */const config = getDefaultConfig(__dirname);config.transformer = { ...config.transformer, babelTransformerPath: require.resolve('react-native-svg-transformer/expo'), assetPlugins: ['expo-asset/tools/hashAssetFiles'], getTransformOptions: async () => ({ transform: { experimentalImportSupport: false, inlineRequires: true, }, }),};config.resolver = { ...config.resolver, assetExts: [...config.resolver.assetExts.filter((ext) => ext !== 'svg'), 'lottie'], sourceExts: [...config.resolver.sourceExts, 'svg', 'd.ts', 'mjs','wasm'],};config.resolver.unstable_enablePackageExports = true;module.exports = config;
No matter what I try to change this issue doesn't seem to go away.
How did the rest of you make .lottie files work?
Steps to reproduce
Try the snack
Snack or a link to a repository
https://snack.expo.dev/@xchikux/arrogant-orange-chips
Lottie React Native version
7.2.2
React Native version
0.79.6
Platforms
Android
Workflow
Expo Dev Client
Architecture
Fabric (New Architecture)
Build type
Debug app & dev bundle
Device
Real device
Acknowledgements
Yes
Metadata
Metadata
Assignees
Labels
No labels