Skip to content

Instantly share code, notes, and snippets.

@riccardoscalco
Last active August 29, 2015 14:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save riccardoscalco/567aaa0390dcfb4d7aa6 to your computer and use it in GitHub Desktop.
Save riccardoscalco/567aaa0390dcfb4d7aa6 to your computer and use it in GitHub Desktop.
Multiple charts with flexbox
<div class="container">
<div class="Grid">
<div class="Grid-cell">1</div>
<div class="Grid-cell">2</div>
<div class="Grid-cell">3</div>
<div class="Grid-cell">4</div>
<div class="Grid-cell">5</div>
</div>
</div>
.Grid {
display: flex;
flex-direction: row;
flex-wrap: wrap;
justify-content: flex-start;
}
@media (max-width: 540px) {
.Grid {
justify-content: space-around;
}
}
.Grid-cell {
background-color: gray;
width: 250px;
height: 300px;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment