Last active
April 13, 2016 20:54
-
-
Save davidohlin/6dff6b724c16ac0d1104b195d8875f73 to your computer and use it in GitHub Desktop.
Remove all suggestions on what to do as a designer from Designer News.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var title; | |
var story; | |
var garbage = ["should", "designers"]; | |
var stories = document.getElementsByClassName("list-story"); | |
for (var i in stories) { | |
story = stories[i]; | |
if ( story.classList.length === 1 ) { | |
title = story.getElementsByClassName("story-link")[0].getAttribute("alt").toLowerCase(); | |
if ( check(garbage[0], title) && check(garbage[1], title) ) { | |
story.style.display = "none"; | |
} | |
} | |
} | |
function check(arr, str) { | |
return str.indexOf(arr) >= 0; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Lol! This is hilarious, but so great.