Skip to content

Instantly share code, notes, and snippets.

@jswhisperer
Created January 14, 2014 17:26
Show Gist options
  • Save jswhisperer/8422168 to your computer and use it in GitHub Desktop.
Save jswhisperer/8422168 to your computer and use it in GitHub Desktop.
Vertical align with CSS
.element {
position: relative;
top: 50%;
transform: translateY(-50%);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment