Skip to content

Instantly share code, notes, and snippets.

@mehmetsefabalik
Last active January 21, 2020 12:42
Show Gist options
  • Save mehmetsefabalik/a734ffbe5bc4e8d17c839ae3b1d3082b to your computer and use it in GitHub Desktop.
Save mehmetsefabalik/a734ffbe5bc4e8d17c839ae3b1d3082b to your computer and use it in GitHub Desktop.
css text overflow example with one line and multiple lines
.one-line-overflow {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.multi-line-overflow {
white-space: normal;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment