Date: 2017-06-08 08:36 pm (UTC)
oio11: (Default)
From: [personal profile] oio11
10 very good reasons to stop using JavaScript - LeaseWeb labs

Now brace for the 10 very good reasons to stop using JavaScript: 1. JavaScript hurts your mobile visitors Yes, you heard me right! Do you think that 600 Mhz CPU of the mobile device used to visit your site will execute the 10.000 lines of JavaScript you added (or linked) in your page? It does, but your visitors won’t wait for it. And how much memory do you think your cleverly AJAX loaded DOM objects take in the browser memory? Try using the Google Chrome Heap Profiler and double-check your findings. You need to because they are that high. You may want to read Who Is Murdering PhoneGap? It’s jQuery Mobile as a reference.

2. JavaScript hurts your robustness A single bug in your JavaScript can break the functionality of your entire website. Especially when you are relying on one of the above MVC frameworks. And you cannot test against future browser implementations of JavaScript, can you now? I feel JavaScript should only be used to enhance a website. If it is not available or it fails, it should degrade gracefully. This means that your website should still work, albeit less conveniently or pretty. Even better is the related concept of  progressive enhancement.

3. JavaScript hurts your security (and your privacy) XSS and XSRF are the acronyms most web developers do not understand. Let’s keep it that way, because hackers and security consultants are making good money on them. No kidding, I think that knowledge about these subjects is much more important than your client-side script-fu. So if you are using JavaScript, but have no idea how to avoid these attacks, then please, for the sake of the web, stop using JavaScript (and start reading some security books). AJAX based content loading and form submission are often vulnerable to these kind of attacks. Also automated security tools often fail at detecting these issues, since they rely on HTML parsing, which is not possible when using AJAX.

4. JavaScript hurts your SEO Yes, that is right, we are talking about Google’s almighty spiders that are not (good at) executing your JavaScript. This means that the JavaScript loaded parts of your website will not be indexed. This should not be a shock to you, since this is a well known fact. But it makes investing money in AdWords (for example, e-commerce) and using JavaScript a problematic combination. On the other hand you may be creating a website that is behind a pay-wall or a web application that requires authentication. In those cases the Google spider bots have no access anyway, so you don’t have to worry. AJAX can make a site difficult for search engines to index if the technology is not implemented carefully. There are two main search engine issues around AJAX: making sure that search engine bots can see your content, and making sure they can see and follow your navigation.

This is not my opinion. I’m quoting Google’s advice on applying AJAX:

… view it in a text-only browser such as Lynx. Viewing a site as text-only can also help you identify other content which may be hard for Googlebot to see …

Try a text-only browser like “lynx” or “elinks” and you will be shocked by what Google will see!

5. JavaScript hurts your development time Debugging JavaScripts can be a very tedious task. Especially when your JavaScript codebase is large and it is connected to many events on your DOM. It may be very hard to exactly find out how often and in what order events are happening. Also you have to rely on the debug tools provided by the browser. This is fine for a modern Firefox or Google Chrome, but how about old Internet Explorers? How many hours did you waste on that, honestly? Testing cross-browser and cross-platform is expensive because of the numerous combinations possible. This form of testing is needed, because implementations differ, since there is no JavaScript standard.

6. JavaScript hurts your testing costs Test driven development often relies on functional tests executed by test robots (much like Google’s spider bots). This form of automated testing relies on parsing the generated HTML. But JavaScript applications cannot be tested without the actual use of a browser, causing the testing to become very complicated and expensive. I have seen whole server farms being setup to automate the testing of a web application in different browsers on different operating systems. And the costs are not only in building such a setup, you should be mainly concerned about its maintenance costs.

7. JavaScript hurts your website performance Lots of people are using AJAX to load multiple parts of their website in separate requests. Where you normally have one request for the HTML, the web server now handles multiple requests for HTML from the browser. That way the web browser is tricked into thinking that the website is loaded after the first request of HTML. This allows the visitor to look at something (which according to some UX guru’s is important), but it will slow down the actual loading of the website. It is even worse if you consider that this behavior will put a higher strain on your web server, resulting in slower serving of the page during peak hours (when it matters most).

Also interesting to read is that JavaScript may slow down your website due to poor JavaScript performance.

8. JavaScript hurts your software investment Client-side technology is doomed to fail. We have seen Java applets fail. Then we’ve seen Flash fail (under suspicious circumstances). If history repeats itself (and it mostly does), JavaScript will fail as well, since it is the third in it’s kind. When exactly is still unsure, but investing a lot of money in a codebase built on such an uncertain platform seems like a huge risk to me.

9. JavaScript hurts your software architecture The reason the above MVC frameworks are on the rise is easy, there is no good way to write substantial software in JavaScript. The lack of any traditional OOP structures drives programmers mad. MooTools tries to fill that gap by providing just that. A good try, but it is still a hack that is lacking a lot of core OOP principles. These things frustrate professional and experienced programmers, since they are simply not used to write in functional languages. How many programmers that have a professional education actually know how to do functional programming? And how many are good at it?

10. JavaScript is not needed Yes, you can create websites and applications without JavaScript. Everything that is possible in JavaScript can be done on the server side. But this is not how we roll, right? We need “new” and “cool” technology don’t we? Otherwise we (web developers) would be bored. But I ask you, can you look your boss straight in the eyes arguing that you “need JavaScript”? Is there a valid business case? Does this technology really pay off? A lot of web development is done on applications that consist of lists, forms and buttons (administrative applications). Those applications definitely do not need JavaScript. People creating games or other real-time experiences, may consider themselves lucky, they are excepted.
Anonymous (will be screened)
OpenID (will be screened if not validated)
Identity URL: 
Account name:
If you don't have an account you can create one now.
HTML doesn't work in the subject.


If you are unable to use this captcha for any reason, please contact us by email at

Links will be displayed as unclickable URLs to help prevent spam.

October 2017

12345 6 7
89 1011121314
151617 18192021

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Oct. 18th, 2017 12:47 pm
Powered by Dreamwidth Studios