Skip to content

Instantly share code, notes, and snippets.

@ackintosh
Created November 10, 2012 05:59
Show Gist options
  • Save ackintosh/4050100 to your computer and use it in GitHub Desktop.
Save ackintosh/4050100 to your computer and use it in GitHub Desktop.
Using the jQuery Masonry
<div class="masonry">
<article class="masonry-brick">
...
</article>
<article class="masonry-brick">
...
</article>
<article class="masonry-brick">
...
</article>
</div>
<script src="/javascripts/jquery.masonry.min.js" type="text/javascript"></script>
<script type="text/javascript">
$(function() {
$('.masonry').masonry({
itemSelector: '.masonry-brick'
});
});
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment