Personally, I like Javascript. It’s fun to work with. It’s sometimes a bit annoying, but I’ve yet to work in a language which didn’t have it’s annoying parts.
Mike, you’re perfectly right, of course. My point remains that what happened to scribes thousands of years ago is now happening to programmers. Don’t you find it strange how defined we are on the marketplace by the languages we use when it’s those skills that go beyond mere syntax and grammar that makes professionals distinct from amateurs?
I expect, or rather hope, that with the democratization of programming, we’ll come to value the craft over the command set, just as we’ve come to appreciate the work of writers that lie beyond grammar. On second thought, I think it’s rather the work of designers who can manage some code that will be appreciated over the ability to program well.
(And, yeah, I also felt like getting some frustrations out of my chest. Maybe I should have abstained…)
I just want to recommend a website. QuirksMode:
a href="http://www.quirksmode.org/about/intro.html"http://www.quirksmode.org/about/intro.html/a
tndal, your link is a red herring. That’s how many of the sampled sites USED the technology, not how many people use it or how many browsers support it.
Unless you’re going to tell me only 10% of people can view iframes and css only has a 54% market penetration.
HTML was designed to describe documents, not applications - the fact that Google Calendar can be written to that collection of ugly APIs points to the flexibility of the system. HTML’s success can also be, in part, attributed to its ugliness; show me a binary format that accomplishes what HTML does and I’ll…wait a minute, it doesn’t exist. Web development is ugly, but until someone comes up with another “sweet spot” API that is visible to search engines and can reach anyone with an internet connection and a five-year-old piece of software known as “the browser”, it’s here to stay.
For more on this topic, you may want to check out this book:
http://www.amazon.com/Weaving-Web-Original-Ultimate-Destiny/dp/006251587X/ref=pd_bbs_sr_1/104-6382103-6883909?ie=UTF8s=booksqid=1179859065sr=8-1
As an FYI (and although it’s not always directly related to Javascript), Douglas Crockford’s blog can be seen here:
http://blog.360.yahoo.com/blog-TBPekxc1dLNy5DOloPfzVvFIVOWMB0li
JavaScript is our friend. I’ve spent many long, tedious hours pouring over JavaScript code developing new techniques and perfecting syntax. What have I gained from it? A rich user interface for my web applications that gets jaw-drop responses when I show it to customers.
You can even write your server side stuff in javascript if you want.
https://www.zimki.com/info/whyzimki.html
thats a blatant plug by the way.
Ivan: “… and I’m sure you’ll come to the conclusion that browsing the web with something like the http://noscript.net extension is the only way to go these days”
It’s not XSS (I’ve never personally witnessed it anywhere), but it’s the plethora of stupid “popups”, scrollers, AJAX, this and that. It’s absolutely horrible when you stumble upon a site which loads half a megabyte of memory-leaking, performance-reducing JS. Take your stupid gigantic JS libraries and shove ‘em where the sun don’t shine. I’m on a metered connection, damn it! You have 30 KB of content, and 300 KB of JavaScript – I’m looking at you right now, f***in’ Flickr! What do you need the JS for? What???
I have both JS and Flash globally disabled, and I enable them on a site by site basis. Maybe. If it’s really, really important, and I cannot choose to ignore a particular site, as I usually do; the sure way to have me never visit you again is to rely on JS for your functionality. I even use Gmail with JS disabled, as I cannot stand the stupid AJAX stuff breaking my back button (that is, my mouse gesture). Oh, and Gmail loads and runs faster, plus is more user-friendly, with JS disabled.
People who have JS and Flash disabled are growing in numbers. Ignore THOSE people at your own peril.
You can even write your server side stuff in javascript if you want.
Um, you missed the boat by around a decade. Both Netscape and Microsoft offered server-side Javascript back then.
Ivan: I would have to agree with the sentiment about browsing with flash and javascript disabled – and only allowing on a per-site basis.
Dozens of sites require javascript for basic functionality, and don’t bother degrading to GETs or POSTs. Laziness or evidence of this move to depending on the availability of javascript in the browser?
Haacked: I remember InterDev having a javascript ‘debugger’ in the style of visual studio. Hovering over variables to see their values and such.
“Oh and btw Javascript does ‘work properly’ its just some browsers handle it better than others…”
Like I said before, it’s not JavaScript’s fault. It can only provide the functionality that is agreed upon by the standards commitees which move at a snail’s pace. It is crippled by the lackluster set of features available from the DOM provided by the likes of HTML.
For example, there is currently no simple way to determine which control on a page has focus. This is not a JavaScript deficiency. But it will take years before the w3c actually gets their act together to do something about it.
And this is another reason why commercial products like WPF/e (Silverlight), Flash, and others will always provide a much richer programming model than will JavaScript/HTML. If they recognize that something is missing they just add it in the next release. There is no one to quibble with and they don’t need every browser maker in the world to add compliance. Sure, you must force users to upgrade to the latest version of the plug-in. But so far, Flash hasn’t had any problems getting people to do that. People are willing to upgrade a plug-in. They are NOT willing to upgrade their whole browser or OS.
Matt:
“People are willing to upgrade a plug-in. They are NOT willing to upgrade their whole browser or OS.”
I would have to disagree. People are perfectly willing to upgrade their browsers. The problem is that browsers (particularly IE, but all browsers in general) don’t get updated nearly often enough. And, as you said, there isn’t enough reason to upgrade given how glacially slow the standards committees move.
I also like to say that I agree with several of the other commenters: JavaScript is a good language in its own right. But I cringe every time I have to use it because of the platform it targets. htMl is a MARKUP language; as Geoff said, it was intended to describe documents, not create dynamic interactive applications. JavaScript and everything that has come after it exist soley to transform html documents into something there were never intended to be. Do javascript/asp.net/ajax/flex/silverlight/etc work? Mostly. Will building rich dynamic interactive applications on top of a markup language ever be a good plan? Not a chance.
That said, its what we have, and its not going away anytime soon. But I am constantly on the lookout for the technology that is going to sink it someday.
For the last 6 months, I have been working on creating javascript on rails. If anyone is interesting, we are planning on making the framework open-source. Check it out at:
Feedback is greatly appreciated.
On somewhat of a tangent, but for those looking for a cool Javascript IDE, check out Aptana, www.aptana.org - you even get Javascript intellisense!
It is coded in Java, so takes a bit longer to load, but still great to use. Just wish they’d get a color picker in there for CSS editing…
http://blog.outer-court.com/archive/2007-05-23.html#n73
–
Andrew emailed this question: “What happened to the Google search engine last week, I can’t see the buttons for image and news what changed?” After we emailed back and forth, it turns out that for security reasons, JavaScript had been disabled in Andy’s browser. Without JavaScript, the corner navigation won’t load anymore (see screenshot). This seems to be a new level of inaccessibility in Google homepage designs, but then again, pragmatically speaking without JavaScript you just won’t get very far online in the first place these days…
I agree with Toni.
Javascript is off by default.
90% less security holes (if not 99.9%), no annoying sounds or animations on tacky websites and less ads. I save myself many problems by treating javascript like the plague.
Javascript has its uses, but I do not trust everyone to use it wisely.
–
Rune
Just take a look www.extjs.com
It’s the best JS library I’ve ever seen.
Not only wonderfuly UIs, but nice code!
Oh I love javascript, big ups! Seriously. Dynamic!!!
I still think the best way to do things is degrading javascript gracefully. Even if you are making a complex web application, you can still layout all your text and information, with regular links that will refresh the page to do what you want. Then go back and have javascript (in an external file) cancel those links’ default action, and perform ajax routines instead.
For more information on how to do this, I also look at http://javascript.codeislogic.com/
Interesting! And Nick, thanks for the javascript Link
Many Gracias from Germany