203 points · by Wilya · 14y ago · 197 comments
Sure, you enable JavaScript but you don't disable AdBlock and so now you're just consuming resources and contributing negatively to the site you're visiting's bottom line.
I understand the myriad justifications for disabling JavaScript, but I don't really care. There aren't enough people with JavaScript disabled to warrant giving it any attention.
It's the same with Flash. If you don't have Flash, I will show you how to get it, but I'm not going to spend the time telling you why you ought to get it, because I don't care to argue the point. There aren't enough people without Flash for it to be a concern.
If you have to use Flash, then that's fine. But the author of the article is right IMO. You need to provide a compelling reason for me to hop off my iPad and boot up my workstation/laptop to look at your website.
I have long considered that Unobtrusive Javascript to be one of the best paradigms for websites. It shouldn't be that hard to do. In fact, even in web applications there should be a clear seperation of content and behaviour, just as there is to seperate content and style. I was looking at a VMware product the other day that does ITSM, and it was the most god-awful mix of bad Javascript and HTML that I was most surprised. Not only did it not use Javascript in a sensible way (ala jquery, YUI, etc.), but it used stupid tricks like document.all - and in fact the webpages that it loaded entirely relied on Javascript working.
Therefore, I submit to you that by not designing your websites with Unobtrusive Javascript, that you are a. causing accessibility issues (and NOT just for disabled users), and b. you probably haven't developed your website very well anyway.
Please, I urge you to convince your users WHY they need to turn on Javascript to use your site. If you can't provide a compelling case, then I'd suggest that you probably don't have a good reason to require it!
If you can't access a website because Javascript is turned off, then I think you are overcomplicating things anyway. There are obviously cases where it is required, but as the author states, it should be pretty easy to explain why you need to enable scripting!
That's not really true anymore, given the 200 million iPhones kicking around.
I'd hope an amicable, intelligent developer would. Scripts don't always load. Errors happen.
> I understand the myriad justifications for disabling JavaScript, but I don't really care.
How nice of you to pick and choose users that matter. It must be a nice luxury.
/s
I'm the opposite: I run NoScript but not AdBlock.
In fact, if I like your site, and it happens that NoScript is blocking your ads, I'll make a point of letting them through. http://www.projectwonderful.com/ is on my whitelist, for instance.
When people sneak snacks into a movie theater they are not thinking "I am going to subvert this theater's business model". They are thinking "The normal way of getting snacks at the theater is unacceptable to me".
The same is true with AdBlock. Nobody thinks "Mwahahaha, I'm going to financially ruin some content creators." They think "if I see one more punch-the-monkey ad, I'm going to punch an actual monkey".
I mute TV commercials, I change the station on the radio when the commercials start, and I use AdBlock by default. If I really like a site, I will turn AdBlock off and see if its ads are acceptable. Usually, though, I turn it right back on.
One example was my local newspaper, which put this flash overlay of a local bigmouth car deal floating in the middle of the screen -- in a area that you typically click on.
I click it by mistake and end up with a high-volume "it's huuuge" booming across my office. Screw that... adblock=on.
There definitely is a good argument for catering to those who cannot use some features, like Flash, but to those imposing these restrictions upon themselves, you know how to solve it.
I consider myself fairly "tech-savvy" as well and have not seen more reasoning behind turning JS off than for leaving it on.
Also, the amount of no-Flash users is increasing and will most likely do for years.
1. Decide if the core of the site is undoable without JavaScript. Something like Google Docs or games relying heavily on Canvas/WebGL are prime examples. It is very rare for this to be the case, but if it is then disregard the rest of the steps.
2. Build the entire site without even considering JavaScript as an option. The advantage of this is I can finish all functionality without opening my browser window once. I build out the core with unit tests, and assert the base user workflow using integration tests that can simulate things like form submissions to route end-points. My test suite is now a constant confirmation that my site works with JavaScript disabled.
3. Open up the site in a browser, and begin the design & UX portion of development. Because the site is essentially feature-complete and tested already, I can have a lot of fun experimenting in this stage, tweaking things to my heart's content.
4. I slap this on the page after I'm satisfied with the enhanced UX that design and client-side scripting provides:
<div class="jsnotice">
We notice that you currently have Javascript disabled. While this site is fully accessible
without it, you're still missing out on some pretty neat features. We work tirelessly
to ensure that our scripts are small, unobtrusive, and do not harm your user experience.
Please add us to your whitelist, or <a href="//enable-javascript.com/">enable Javascript in your browser</a>!
</div>
Using Modernizr, that class only shows if JavaScript is disabled. The message itself is unobtrusive, and I always provide a way for the user to dismiss it permanently. If I want, I go into a little bit of detail on what "features" they're not experiencing fully.True Story: I worked for a while on a website where users would upload and share tutorials on various topics. As the company behind it grew, it had the genius idea of selling print copies of their best tutorials. At some point, we were looking for a Python tutorial to publish. We select our favorite one, get in touch with the author and were genuinely delighted to find out that he was blind, accessing our app via screen reader.
He went on to publish a book (last I heard selling at over 10 000 units in less than a year topping Amazon's sales in its category). It was our app (the general focus on accessibility, independance from Js was a big part of it) that allowed this cool blind kid to publish a best sellers book. The odds of something like this happening, clearly, aren't very high, but when they do it's instant gratification for the developer who worked on making it accessible.
If you're too hung up on numbers and ROI, think of all the benefits the company got from the positive exposure it gathered from the press around the incident. In any case, unless the core of your app is in JS, it's always a good idea to provide alternatives.
Shouldn't we fix the screen readers, rather than fixing every website?
Any solution to any problems that begins with 'first change the world' is not a valid solution as the project will never get past that stage.
The world would be a much better place if the effort and money spent on making ramps was spent on wheelchair provisioning and development.
The instant the site fails the decision has been made.
If your site breaks without js you must at least realize that you will, at the very least, annoy the users who has actively disabled it.
Good examples of some problems I've seen are Twitter taking several seconds to load content, even when the javascript is cached (somehow facebook does it fast enough). You even have a webpage like this "http://www.html5rocks.com/en/tutorials/internals/howbrowsers...? that seems laggy when scrolling with js.
Though, I do get the gripe about not even seeing what the site is about before enabling JS. Even the weakest IE6 experiences seem to have some semblance of the subject matter.
Not quite: the major issue with IE6 is that it fucks things up by providing partial implementations. A no-scripted browser "just" provides no scripting, static content and styling are perfectly handled just not additional behaviors.
These are very, very different situations.
That's dramatically easier than trying to make a complex app work in IE6.
It's more helpful to think about designing a site to work robustly for the situations in which JavaScript doesn't successfully run. There could be reasons from aggressive firewalls blocking scripts, to slow or broken network connections, where the user might not get your JavaScript along with the page.
Many browsers halt all JavaScript execution on a script error. All it takes is a badly coded third-party ad on your page, or a typo in your own code to stop all JavaScript on the page from running.
Is it right that your page or app should completely stop functioning at that point? The web is a brittle platform. Things break all the time, but our technology stack of HTML, CSS and JavaScript can be exceptionally robust when used in the right way.
Build your site with HTML. Make it look much better with CSS. Make it work much better with JavaScript. Be prepared that CSS or JavaScript may not load at any point, with the reassurance that plain old HTML has got your back.
Sure, it takes a bit longer. Doing a good job always does.
If I'm building something JS-only, I try to speak the NoScript user's language when writing the error copy, even attempting to build a bit of rapport, like here: http://presteign.com
[EDIT] Something has apparently gone wrong in the last couple of days with the dynamic content loading on the site linked above, so I've put a maintenance page in its place. The <noscript> message was: This site needs JavaScript enabled to work. At least it's not Flash, right?
Enabled the site in NoScript and all I get is a very buggy menu. OK, lets give you cookies, real referrer, etc. Still not working??
Just for you, I've made a brand-new Firefox 11 profile with no extensions and all default settings. The site refreshes every second, spewing warnings in the JS console. It looks broken and I still don't know what it is about.
Whether a site this simple really needs JS is another discussion...
I just updated the parent comment with a warning.
It's up again. Turns out it was an .htaccess I had mistakenly pulled out of the webroot a few days ago. The JS couldn't resolve any of its AJAX, and I didn't build it to fail the calls gracefully.
Then tell us that. I'm serious, I'd rather get a "fuck off" message than one assuming I'm an idiot.
Nobody is saying you have to support non-Javascript users. The author is saying that if you want to support us, then get it right.
You're the one who stands to profit from the interaction. You do the legwork.
Seems a little silly to me, if you know java-script is disabled then you should just ignore the link.
Well said. Thank you.
Each mortal thing does one thing and the same:
Deals out that being indoors each one dwells
...and he then calls for humanity to rise above this standard case. It is functional, if sub-optimal[2], for how we can organize society: every single person complains about what bugs them, and we connect the social graph dynamically to make people happier -- the people who want a NoScript user's business will design with them in mind, the people who don't care enough, won't.I would add that this applies not just to JavaScript but also to cookies. We use NoScript and Cookie Monster because they're condoms for the Internet -- they protect us from tracking cookies and some XSS attacks.
The web site for Priv.ly unfortunately breaks when you use NoScript. The reason for the break is to make four links appear when you mouse over an image which is hiding them, and then those links load videos into that element. Basically, the element is an iframe for videos, except they didn't use an iframe. It would have been faster to develop if they had just used an iframe to load their videos, and then their videos could probably be covered by a NoScript exception for Vimeo.
If the site didn't break, it would say, "You do not have scripts enabled, which means you are either running old technology, or are our kind of person. If you are the latter, we hope you will consider helping out." This is almost very nice and polite -- but please, skip the crap about "running old technology" when you follow-up on this example, and instead just condense the content which you were going to show me into a short summary with a nice little end point, "to see my app, please enable JavaScript." If your app is its own summary, like a blog article, then you absolutely should not require JS to display it.
[1]: http://www.bartleby.com/122/34.html "As Kingfishers Catch Fire" [2]: http://www.ted.com/talks/lang/en/david_logan_on_tribal_leade... "Different Stages of Tribes"
Hopefully the search engines will fix their spiders. In the meantime we have ugly workarounds like the #!/escaped_fragment nonsense.
body { font-size: 14px; line-height:1.4 }
But I'll bet that there are more IE 6 users than Noscript users.
They may not be able to though, take something like Etherpad there is very little value it can provide when javascript is disabled so being upfront about it makes sense. An other acceptable excuse is not having the manpower to handle both experiences correctly.
Of course, the most common case is likely that they can't be arsed.
No, I'm going to continue to blame that subset of JS coders who consume far too much of my CPU/memory resources. Thanks to them, I got to watch my browser slow to a crawl and become so unresponsive that it was difficult to even close the tab containing the offending site. The simplest solution is to have JS off by default. A whitelist system is nice for non-offending sites (I've never had this sort of trouble with JS on, say, HN).
-Page loads, great
-Click on something but it doesn't respond
-Shit, probably JS
-Click NoScript, see a list of sites
=This is where is really gets good=
-Stare at the list of sites noscript is blocking on the page, arbitrarily unblock one that 'seems' like it would be hosting the code that runs the thing I'm trying to fix, based only on domain name
-Refresh the page, try clicking that thing again, if it doesn't work, repeat the process
I wasted many hours of my life on that process, and what did I gain from it? Security? Not really, since I would randomly enable sites to run JS. So I uninstalled it. Worst case scenario, I get a virus and have to reformat, and lose an hour or two. I don't have any important data on my hard drive.
So, Noscripters, are you guys just really concerned about security or is it a psychological thing - as in, it feels good to be able to be the boss of your browser and tell sites whether or not they can run JS?
Most Javascript is gratuitous.
Odds are I don't care enough about your site to Like, +1, or Tweet it.
Odds are I don't really intend to purchase a BMW, meet hot singles, or reserve a room at Days Inn based on a display ad.
If I care enough about your site to click on something and it doesn't work, I might allow scripts to run but I have to want to see what your site has. Each round of allowing scripts increases the odds I will navigate away. Clicking to allow javascript doesn't bother me because most of the web is a waste of time to begin with and Noscript makes me more selective.
Websites which rely on javascript essentially ask me, "Do you really want to look at this." Much of the time, the answer is no.
Then I get the benefits of security and not being tracked everywhere I go.
- a vimmer
And it's not just about security: http://news.ycombinator.com/item?id=3836601
As a less-intrusive compromise, I use Ghostery now, which lets me zoom in on a lot of the common third-party JS without cluttering the view with "normal" stuff like jquery and friends, because they keep a curated list.
I disagree. Anyone who has JS disabled in 2012 is not tech savvy. They are a paranoid weirdo. They're the guy who refuses to buy a TV even though the Wire, Breaking Bad and Justified are on.
Nobody should have to waste their time trying to convince you to be sane.
I am pretty sure this qualifies as "tech savvy".
Nobody would have to waste my time convincing me to turn on Javascript if so very, very many sites didn't spend so much time using Javascript to degrade their site's experience. Don't bother trying to convince me this isn't the case, I have years of concrete experience proving the opposite. Theoretical arguments about how that might not be true aren't going to fly.
Forgetting about Netflix on your pc are you? In fact, watching shows on a specific channel as opposed to via an on demand service such as Netflix is actually a worse experience. Because I watch things when the TV channel decides, as opposed to when I want to watch things.
I have a TV. I haven't switched the channel off of my ps3 once. Everything I could ever want to watch is on there.
PS: just about every legal streaming site is unavailable outside USA. Or outside 10-15 premium countries in best case.
But that doesn't change the whole DVD solution.
Fobbing someone off to a patronising "how to enable JS" page is more of a waste of time than showing them a screenshot & paragraph description of what they're missing out on. It's about as much effort, and drives them away, while giving them a preview may actually earn you a customer - the very opposite of "wasting time".
P.S. I love Breaking Bad and Justified, but I don't have a need for a TV any more, still have one, but rarely turn it on. If I want to watch them, I just go to Amazon/iTunes/Netflix/Hulu and stream them.
Keeping my computer secure is more important than using the latest ridiculous web app that slows my computer to a crawl.
Enabling JS is free.
If your webpage doesn't display anything without javascript, or if it doesn't display anything except "please enable javascript" or "here's a link to tell you how to enable javascript", then please take the extra minute to add something like the following to your webpage:
<noscript><span style="color:red">This site about X requires scripting because Y.</span></noscript>
That's it, shortening/assuming context/lengthening as desired. Warning that your site will/will not be using your browser to mine bitcoins for the owner is optional. Recoding your site so it works with lynx is also optional and fine, if you really want to, but it's not what's being asked.Javascript is to enhance the web, the crux of all webapps. Going around to disable it, then enable it for half the websites you encounter, kinda seems overkill to me.
I definitely see the advantages though. It's much faster, and you don't get disturbed by anything. Ideally I'd automatically get every article I go to from HN trough readability first. But doing that is slower than just letting my computer load the thousands of lines of JS, and not everything from HN is text. I can live with the nonsense on the page as long as adblock plus is turned on. Actually every news website should go trough readability, or at least get the "share it with your friends on Facebook, G+, Twitter, email, print, delicious, stumbleupon, digg, or by direct link" blocked by adblock plus. But disabling Javascript just for this?
My website also has a message for people who don't have Javascript enabled. It does aim for an average user who doesn't know he has it enabled since one of the priorities is to get the broadest possible compatibility, but that's just one sentence linking you to where you can read more if you want to.
One of the things I promise in the more info is that my Javascript won't ever be intrusive in any way. For example I use it to load Disqus comments, or to toggle visibility of fields when you click something. JS is not required to navigate or get all content though.
Very often websites that don't work without JavaScript have serious design/privacy issues, which better be fixed even if no one disabled scripts. Very often the reason those websites require scripts is because the developers working on them are incapable to conceptualize desired business logic using some simple mental model, so they just throw random code and libraries at the issue until it seems solved.
Saying that "it's an app" is a common, but very weak excuse. Most websites are not doing anything that would warrant them an app status. They simply use JavaScript to enhance browsing experience. That's perfectly fine, but the inability to isolate those enhancements from code logic that's required to make the website work is indicative of the problem that I described above.
I'm not sure I understand your logic here. Many sites use javascript for advanced features not possible otherwise. I don't see how not working without javascript equates to privacy issues.
Stuff like including Google's JavaScript by linking to Google's servers equates to privacy issues. The fact that some websites don't work (at all, don't even render) without external scripts is a design issue. These issues often come hand-in-hand, but no one said that one equates to the other.
Also, if your notion of "advanced features" includes rendering of text and images and working links, you might consider re-thinking it.
I wouldn't want to browse with anything but NoScript, CS Lite, RefControl, Adblock Plus and Ghostery. If your site doesn't work, too bad for you. I'm not the person who makes a living selling stuff on the interwebs.
The "Gawker Experience" (white page, nothing of value is lost) is quite common, and I like it.
There are useful applications of Javascript, but they are rare. You have to show me that it's useful to me, and I will then give you my CPU time. Not the other way round.
I guess the only way to know how relevant it is to cater to noscript users is to measure how large a chunk of potential customers your leaving behind relative to the cost of fixing your site to work without JS.
Bingo. Since I first installed NoScript, I've started noticing a correlation between how gracefully your mostly-static website degrades without javascript and how worthwhile your content is. Those that fail completely rarely have anything worth looking at on them anyway.
If I understand it correctly, OP was redirected to a dumb-down instruction page of how to enable Javascript in his browser. What he actually wants is the reason "why" he must enable Javascript for the site.
You can win over noscript population very easily by taking a little bit of time and explaining your app with some amazing screenshots.
My prejudiced view is that it's such a small part of the population it's not worth caring about, though I'd be glad to be proven wrong.
If doing pages that require javascript to even run in the first place is a good idea, I think is a different discussion.
It also depends greatly on the kind of web app you are making. If your audience is highly tech-savvy then caring about noscript population will increase your userbase.
<noscript>To enjoy all this awesomesauce, please enable javascript:
<img src="/annotated_representative_screenshot_you_should_already_have_for_the_tutorial_page.png" />
</noscript>
Wave some CSS at it to center it nicely; done."Warning: A browser setting is preventing you from logging in. Fix this setting to log in"
Sigh.
If you have a site, it's your choice to either ignore us (like the Google Blogs) or not, but if you don't want to, then the author has a point: tells us why, not how.
Just who is needing who here ?
Then say that, don't be a condescending prick. It's ok if you're not interested in that part of the market, just buy a pair of balls and say it.
Out of curiosity, what are those reasons? Related to privacy? Annoyed by animation?
* Obnoxious and gratuitous animations - yep, that too.
* Pop-up/floating/video ads - static or near-static ads are fine. However, if it covers up the content, or makes a noise, it can go die in a fire.
* Badly-written scripts, or pages where there's half-a-dozen+ streaming video ads, can bring my creaky old laptop to its knees.
* There's a possibility (albeit small) of security holes in the browser's scripting engine.
* Personally, I consider graceful degradation a metric of the quality of a website - if it craps out without good reason, that reflects poorly on its owner, and is going to make me suspicious of the quality of their product.
I'm sure there's more, but that's all that spring to mind for me at the moment.
The only times I can see the need for Javascript is to enable something totally compelling that requires the use of it - like an amazing animation that needs JS, or something like this.
In my opinion with the multitude of great new JS libraries (particularly knockout, backbone etc) and JS browser features we're going past it being as simple as progressively enhancing your site. If you are a startup trying to do things in a lean fashion it must be hard to justify.
This is highly dependent on a number of factors, mostly:
* The kind of site we're talking about, if this is a real-time chat application it makes sense that it can't work without JS, if this is a company site or a presentation site for an appstore application with an embedded video and you can't make it work without JS you don't know what you're doing.
* Whether this was considered from the beginning or whoever built the site just went wild with javascript without consideration.
And even in the first section of the first case, if the unlogged account-less front page can't work without javascript I'll probably still think you don't know what you're doing.
Generation Y and our "evil" javascript enabled browsers will take over Generation X in years to come.
As long as I normally focus on the 80% of the users, and more that 80% of my users use javascript, I have to say, that you are not part of my target. I don't have the money to make an app for the user with a normal browser (including mobile), and the user with IE, ups, sorry, the users without javascript.
Buy a better computer
I really don't understand why anyone'd even react to missing JS. Anyone willfully turning it off will be aware of that.
Edit: We disable Javascript because we don't want other people running code on our computers without our consent or knowledge while we browse the Web.
Edit2: Here is some Javascript to peg a client's CPU (this can be malicious or accidental, but either way it's why I run Javascript blockers):
<script type="text/javascript">
function burn_cpu(y)
{
var x = 0;
while ( x != y )
{
x = x+1;
}
}
burn_cpu(99999999);
</script>I don't use adblockers per se and welcome them if they are polite, respect privacy, and something I'm interested in.
"Someone who is thus actually pretty tech-savvy, and who actually took the time to wade through his browser’s configuration to find the switch to turn off javascript."
Or someone who's nephew decided to install AdBlock and NoScript along with antivirus software when they were cleaning up their computer.
I'd go with "someone kooky, wearing a tin-foil hat, a tiny minority, and very unlikely to be interested in what I'm selling anyway".