Skip to content, sitemap or skip to search.

Free Software Foundation

Personal tools
Join now
 
You are here: Home Blogs Community Avoid the pitfalls of the JavaScript Trap on Gmail

Avoid the pitfalls of the JavaScript Trap on Gmail

by Matt Lee Contributions Published on Mar 29, 2011 03:52 PM
Today we're launching the first in a series of features on how to use common websites without using proprietary JavaScript.

You may not be aware of the dangers of JavaScript — a problem we've deemed The JavaScript Trap — proprietary software running on your computer, inside your web browser.

The focus of our first feature is Google's Gmail service.

The JavaScript Trap

When you visit a website such as Gmail, your browser will download and run several thousand lines of JavaScript code. JavaScript code is no different to languages like Python, C++ or Ruby — applications written in those languages running on our computers should be free software, so we can run, modify and share them if we wish. JavaScript today is not the JavaScript of the past — it is now used to write powerful, server-side applications thanks to free software like Node.js and the V8 JavaScript engine.

Further, we've recently seen companies such as Research In Motion (makers of the Blackberry) advising customers to entirely disable JavaScript in the WebKit browser on its devices because of a security problem that was discovered. While free software JavaScript can have security problems too, this example illustrates that we have a real need to be able to see what the code we're running on our computers is actually doing, and change it.

What JavaScript could be doing

It's clear that JavaScript is a very powerful and useful technology in the right hands. Many free software developers have written add-ons and enhancements to popular websites thanks to tools like Greasemonkey. There's a slew of fantastic free software Greasemonkey scripts for Gmail. The existence of scripts like these shows both that Gmail's JavaScript is not trivial, and that there are users who could make useful, interesting contributions if the JavaScript were released as free software for them to modify.

At the same time, sites like Gmail, Twitter and Facebook are relying too much on JavaScript to do much of their work. They prove this particularly with their mobile site versions, which deliver much of the same functionality without JavaScript. Where there is a useful need for JavaScript, it can be released as free software, and where JavaScript provides an optional enhancement, a basic version of a site that doesn't rely on JavaScript can be provided.

Google has made a step toward this goal by developing a 'basic HTML' version of the Gmail website, which does not rely on heavy JavaScript to build the user interface. They also provide IMAP and POP interfaces for users to access their Gmail accounts without using the website at all. These are both good steps towards a larger, positive goal.

A plea to Google: take the next step

If you use Gmail, please ask Google to take the next step towards making Gmail free software friendly by releasing the JavaScript for Gmail under a free software license. In doing so, Google would allow users who value software freedom to use Gmail in its enhanced form, and to make contributions and modifications useful to their communities.

We'd like to hear your suggestions and read your guides for other common sites! You can get started today by adding your ideas and guides at the LibrePlanet wiki.

Document Actions

The FSF is a charity with a worldwide mission to advance software freedom — learn about our history and work.

fsf.org is powered by:

 

Send your feedback on our translations and new translations of pages to campaigns@fsf.org.