Created
October 19, 2016 09:34
-
-
Save ralexandr/463880000445fad6c77194e26ad9bdc0 to your computer and use it in GitHub Desktop.
SASS: Full screen width image inside container with limited width
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
.container { | |
max-width: 600px; | |
margin-left: auto; | |
margin-right: auto; | |
} | |
.full-width { | |
width: 100vw; | |
position: relative; | |
left: 50%; | |
right: 50%; | |
margin-left: -50vw; | |
margin-right: -50vw; | |
.img { | |
width: 100%; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment