Created
April 5, 2017 11:13
-
-
Save hardiksondagar/4c60e674bb04c88e226218c48f319427 to your computer and use it in GitHub Desktop.
Vertically center a div
This file contains hidden or 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
.flex-div { | |
display: flex; | |
justify-content: center; | |
align-items: center; | |
} | |
@media only screen and (max-width: 768px) { | |
.flex-div { | |
display: block; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment