Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Great addition, but why not write it as a userscript instead of Chrome plugin? Chrome, Opera support them natively. You can install it just like an extension. Firefox needs Greasemonkey to be installed but most power users have it anyway. Not sure about IE and Safari but problably they can support userscripts in some way also.


This was just an experiment, and the extension looked like the easiest way to do it (I use chrome 90% of the time).

But I was thinking about publishing the source to github; the js is very simple, if anybody wants to fork it for other browsers is welcome :)

By the way, can you use css files with userscripts?


You can but they need to be hosted somewhere or you need to create a link tag with javascript and add it dynamically...

Something like that:

var css = document.createElement('link'); css.textContent = 'css here'; document.head.appendChild(css);


This is what I was afraid of. By the way, without the css the functionality works anywya, it just looks worse.


If the project is on github, you can just link to the repo for hosting.


I wrote something like this as a user script that works in FF(w/Greasemonkey)/Chrome/Opera a while ago [1]. The idea is to remove individual stories or add filters rather than removing everything like the OP. My script is based on VI-style shortcut keys though so that may influence how useful you find it.

[1] https://github.com/dnewcome/hn-plonk




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: