Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
define [at] appropriately and import jquery and this userscript will take your HNQ troubles away
if( at`*stackexchange.com`||at`*stackoverflow.com`||at`*serverfault.com`||at`*superuser.com`||at`*.askubuntu.com` ){
$('#hot-network-questions li > a:not([href^="http://math."]):not([href^="http://ux."])').closest('li').remove()
$('#hot-network-questions li').removeClass('dno').removeClass('js-hidden')
$('#hot-network-questions > a').remove()
$('.ad-container').remove()
$('#newsletter-ad').parent().remove()
if( at`stackexchange.com` )
$('#question-list > :not([data-sid^="math."]):not([data-sid^="ux."])').remove()
else if( !at`math.stackexchange.com` && !at`ux.stackexchange.com` ){
if (location.pathname in {'/':0 ,'/questions':0 ,'/unanswered':0})
$('#mainbar').remove()
else if( !at`stats.stackexchange.com` )
{ $('#sidebar > .sidebar-linked').remove() ;$('#sidebar > .sidebar-related').remove() }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.