Created
March 19, 2018 15:31
-
-
Save nanlabsweb/033da62f6e83a116ad7d4fd429dd5467 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
componentWillMount(){ | |
if (this.props.source.uri){ | |
Image.getSize(this.props.source.uri, (width, height) => { | |
this.setImageSize(width, height); | |
}); | |
} else { | |
let {width, height} = resolveAssetSource(this.props.source); | |
this.setImageSize(width, height); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment