Isotope filter by URL Hash
<script> | |
// Isotope filter by URL Hash | |
jQuery(document).ready( function($) { | |
// Store # parameter and add "." before hash | |
var hashID = "." + window.location.hash.substring(1); | |
// Set Isotope Container | |
var $container = $('.container'); | |
$container.isotope({ | |
itemSelector: ".item", | |
filter: hashID, // the variable filter | |
}); | |
}); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment