6 ms·
Congrats! Small note, none of the listings appear when using uBlock Origin [ https://chrome.google.com/webstore/detail/ublock-origin/cjpalhdlnbpafiamejdnhcphjbk
by gregsadetsky 10y ago
Congrats! Small note, none of the listings appear when using uBlock Origin [ https://chrome.google.com/webstore/detail/ublock-origin/cjpalhdlnbpafiamejdnhcphjbkeiagm?hl=en https://chrome.google.com/webstore/detail/ublock-origin/cjpa... ], a popular ad blocker.
It seems related to your /js/ads-controller.js file (it gets blocked because of the "/js/ads-" portion in the path).
I would suggest fixing that (and preferably minimizing your JS into one bundle).
- johnwheeler 10y agoOh man - thank you. I was getting reports of the same, and now I know why. Fixed.
- wavee 10y agoStill broken for me. Turns out I have div#ads filter enabled that comes from one of the uBlock 3rd party sources.
- s_kilk 10y ago(To the OP) Maybe change "ads" to "posts" globally in the frontend? Adblockers are are always going to block anything called "ads", even if it's a legit component of your site
- hakanderyal 10y agoSame for 'analytic', 'tracker' and related keywords.
- pjc50 10y agoI suppose it's a philosophical question: if you go to a job ads site, and the adblocker blocks it, is that really unexpected behavior? :)
- majewsky 10y agoWell, you could also go to a job postings site. ;)
- sharemywin 10y agoThat's one of those cases where you can be right and broke or cave.
- madeofpalk 10y agoThis has bitten us in the backside before. We never understood why certain pull requests wouldn't load in Atlassian Stash/BitBucket Server - turns out our adblocker was blocking the page from loading due to having "ad" in the title.
- tempestn 10y agoI've run into that as well. I'm amazed that popular ad blockers still do that, since it's obviously trivial to work around for actual ads, and will result in so many false positives.
- megablast 10y agoThey do it because it works.
- connoredel 10y agoThat's a hilarious comment, and a good point. But you can tell when your ad blocker is messing with site functionality beyond just blocking ads (i.e., the false positives your parent comment mentions). And at a certain point, this is a differentiator among the ad blockers.
- robbles 10y agoIt's incredible that people put up with how buggy these adblocker extensions are. Seriously, blocking an arbitrary URL with "ads" in the path? Can't they just stick to blocking domain regexes instead of actually breaking the web?
- endisukaj 10y agoThe web is broken by all the intrusive ads. I don't mind breaking 1% of the pages I visit if that means blocking ads in 99% of the internet.
- codedokode 10y agoThe one that should be fixed here is a buggy blocking plugin.
- elliotec 10y agouBlock is really good at blocking ads, and a lot of other things that aren't ads too.
- jbyers 10y agoThis is a good reason to never prefix generated Javascript with hex hashes, at least without swapping out vowels. We rolled the dice one and had this happen on Wikispaces once; it was utterly infuriating to debug.
- blaze33 10y agoNice catch, never thought about it. Is it more problematic with preffixes (vs. suffixes etc.) or should we generally avoid any random string? Appending a hash to the script is very convenient to force the download of the new version of an asset (but maybe we have better solutions now, haven't considered this issue in a while).
- imron 10y agoIn your site's code, reference the asset in a path that includes the timestamp the asset file last changed. e.g. /js/1476929634/myscript.js instead of /js/myscript.js Then use your webserver to rewrite /js/<any number>/myscript.js to /js/myscript.js
- Scaevolus 10y agoYou can also do /js/myscript.js?v=1476929634 -- this generally works without any server-side changes. A CRC32 might work better, since controlling mtimes can be annoying.
- imron 10y agoYou can, but that can cause issues with browser caching (http://www.stevesouders.com/blog/2008/08/23/revving-filenames-dont-use-querystring/ http://www.stevesouders.com/blog/2008/08/23/revving-filename...) and in any case I prefer the cleaner urls :-) Plus, once it's configured you never have to worry about it again.
- e12e 10y agoOr just use a decimal hash, rather than hex? Eg in python3: import hashlib as h int(h.sha256(b" ").hexdigest(), 16) > 24725091799402603688614593151141908335745916334489781770578761787218146381928 h.sha256(b" ").hexdigest() > 36a9e7f1c95b82ffb99743e0c5c4ce95d83c9a430aac59f84ef3cbfab6145068 It's longer, but even a 256-hash isn't that long? (and sha1 would probably be fine, obviously)
- bbcbasic 10y agoIf enough people use ad blockers I think they should just make ignoring files and divs with "ad" in their name part of the HTML specification.
- messel 10y agoHah! This is great. "Wait all descriptors containing the letters 'ad' are ignored?" "Madness." "This is HTML!"
- dylanfw 10y ago> "Madness." Blocked by ad blocker.
- adhdlimited 10y agoHaha..just my pint its freaking html
- deleted 10y ago[deleted]
- skrebbel 10y agoAd blockers truly are the new virus scanners. They monitor everything that goes into and out of your computer and randomly break stuff just for kicks. And if that happens, it's somehow the fault of the software provider and not the ad blocker vendor. You can't test against ad blockers (or virus scanners) because the lists keep changing, so you end up applying ridiculous alchemy like not calling your API endpoints "/analysis" but "/computation" and then you just hope for the best. In the grand scheme of things, I agree that the people behind ad blockers are fighting the good fight, but in practice it's become a cat-and-mouse game of "who can break the internet the most". I don't know a solution.
- spurgu 10y agoI don't use any ad blockers, instead I only use Ghostery, which seems to work in a lot more sane way.
- Kiro 10y agoAnd that's one of the reasons I don't use an ad blocker. Not even uBlock Origin, which receives all the praise, is reliable in that sense. I don't understand the crusade against people not using ad blockers by the way. I believe I have good reasons not to. Why do people seem to have a problem with that?
- emodendroket 10y agoWhat "crusade?" I don't care if other people don't use ad blockers; in fact, it's probably to my benefit.
- Kiro 10y agoI was getting downvoted before adding the second paragraph and it always happens when I say similar things.
- Torn 10y ago+1 for the minimizing into one bundle thing. Sets of assets are loading sequentially which is slowing page load down. Your code in each js file seems self-contained, so a simple in-order file concatenation into one .js file as a build step would help. gulp and gulp-concat would do it in a few lines of node, and you'd push the built output to your site. If you end up wrting so much script that a concatenation approach stops scaling, look into webpack and web modules.