You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Static images fail to load in monorepo on iOS #1614
I’m opening this new issue because I’m still experiencing the same bug as in #1599, but the original reporter is not active anymore and comments are closed.
Summary
In a monorepo (Yarn workspaces), iOS fails to load static images imported via require(...) when the image file is located outside the app directory.
Hi @jiroscripts. In #1599 the issue was a misplaced metro config. If you’re experiencing a different issue, we’ll need more details and reproduction to investigate.
I found a metro config that works but you need to make some ajustements to make it works. The key is to define projectRoot at the root of the monorepo cause iOS do not suport uri with double dots (..) inside
It is actually an issue only in iOS in debug mode cause of the metro server assets paths
Activity
robhogan commentedon Nov 15, 2025
Hi @jiroscripts. In #1599 the issue was a misplaced metro config. If you’re experiencing a different issue, we’ll need more details and reproduction to investigate.
jiroscripts commentedon Nov 17, 2025
Hey @robhogan
I tried to place the metro config at the root of my monorepo without any success sadly
I share you some file here to help to debug:
apps/mobile/package.json
package.json
metro.config.js
App.tsx
EDIT
The Console app reports these messages:
dsshard commentedon Nov 22, 2025
In package.json
"resolutions": {
"metro": "0.82.5",
"metro-config": "0.82.5",
"metro-core": "0.82.5"
}
I've rolled back the version for now, and that helped me.
jiroscripts commentedon Nov 22, 2025
@dsshard You rolled back to which version ?
I found a metro config that works but you need to make some ajustements to make it works. The key is to define projectRoot at the root of the monorepo cause iOS do not suport uri with double dots (..) inside
It is actually an issue only in iOS in debug mode cause of the metro server assets paths
Use indexed watch folder paths for external assets
Use indexed watch folder paths for external assets
Use indexed watch folder paths for external assets