Skip to content

Conversation

multimeric
Copy link

Created to solve #1. Basically any props you add to the image-preloader component will be added to the child , allowing you to give the image a fixed height, for example:

var Image = require('react-image-preloader');
<Image 
             src="largeImage.jpg"
             fallback="smallImage.jpg"
             style={{
                 display: "inline-block",
                 height: 342,
                 width: 245
             }}
/>

@AVVS
Copy link
Owner

AVVS commented Jun 8, 2015

Please fix indent and add || '' so that when there is no style prop its not coerced to undefined

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants