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
I reduced my issue to this minimal repro (react-native 0.5.0). I have a png of about 1MB, with smaller images I have no issues.
var image = require('image!name');
works properly, while
var image = require('image!'+'name');
returns "Requiring unknown module...".
My use case would be to have jpg images, and of course 'name' will be a variable different for each image. Will jpg be supported anytime soon? Thanks! E.
The text was updated successfully, but these errors were encountered:
A static analysis done to determine what images to include or not, so doing dynamic images is not supported. At least that is what I assume is going on here.
@browniefed is right. @ecesena please try var image = require('image!name'); with your big image. If you want to dynamically display an image based on its name, write this:
I reduced my issue to this minimal repro (react-native 0.5.0). I have a png of about 1MB, with smaller images I have no issues.
works properly, while
returns "Requiring unknown module...".
My use case would be to have jpg images, and of course 'name' will be a variable different for each image. Will jpg be supported anytime soon? Thanks! E.
The text was updated successfully, but these errors were encountered: