Gatsby: position="absolute" does not work in gatsby-image component

Created on 5 Jun 2018  路  2Comments  路  Source: gatsbyjs/gatsby

<Img sizes={banner.childImageSharp.sizes} outerWrapperClassName={styles.banner} position="absolute"/>

the layout is still:

div class="src-components-MainBanner----MainBanner-module---banner---1jnsz gatsby-image-outer-wrapper" style="position: relative;">

Most helpful comment

Try <Img sizes={banner.childImageSharp.sizes} outerWrapperClassName={styles.banner} style={{position: "absolute"}} />

Looks like the component doesn't care that much for the position prop, but changes it's style depending on the style.position prop

All 2 comments

Try <Img sizes={banner.childImageSharp.sizes} outerWrapperClassName={styles.banner} style={{position: "absolute"}} />

Looks like the component doesn't care that much for the position prop, but changes it's style depending on the style.position prop

Thanks!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kalinchernev picture kalinchernev  路  3Comments

ferMartz picture ferMartz  路  3Comments

dustinhorton picture dustinhorton  路  3Comments

timbrandin picture timbrandin  路  3Comments

ghost picture ghost  路  3Comments