Skip to content

Instantly share code, notes, and snippets.

@msanigar
Created August 11, 2015 16:09
Show Gist options
  • Save msanigar/9a3419a39e8be1353b63 to your computer and use it in GitHub Desktop.
Save msanigar/9a3419a39e8be1353b63 to your computer and use it in GitHub Desktop.
hide elm based on contained text from arr
var _hideStr = ["Shirts", "Jeans", "Shoes"];
$.map(_hideStr, function( val, i ) {
$("#mm_ul .js-mm-sub li a:contains(" + val + ")" ).css( "display", "none" );
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment