Fleegix.org

AJAX devs: client- or server-side?

2005-12-15 12:51:00

A recent post on QuirksMode about JavaScript and "serious" programmers asks the question "Who will create the AJAX apps?"

The post really delves into one of the most fundamental problems that the AJAX boom creates: the push and pull between the old-school client-side devs (like me) who've been doing this JavaScripty stuff for years, and server-side devs, who's bosses are telling them "whip me up some of that AJAX stuff in this next app."

As these AJAXified Web apps continue to push into the traditional app space, there will be more plain old apps programmers or server-side devs forced to deal with the client-side stuff, and more client-side devs expected to do more of the heavy lifting in client-side code.

I think one of the best things about this post is that after highlighting this issue, Peter-Paul immediately heads off at the pass the inevitable response that the problem is a lack of good libraries.

He states flat out that he's not a fan of libraries. Good man -- I'm not a fan myself. And he punctutates his dislike with this really insightful question for the "we'll just use libraries" crowd:

Suppose you're my boss and order me to write a Java application for you, despite my abysmal ignorance of all things Java. I buy a technical reference book, ask around for the best libraries in town, and with these aids start to create my application. Would you, being my boss, consider this a healthy situation in which I'm guaranteed to deliver a quality product to our clients?

This issue isn't use of libraries. The issue is people who want the benefit of new tech without learning how to use it. The post continues by pointing out the obvious: "I feel that libraries are sometimes regarded as substitutes for knowledge. Without knowing a programming language you can't use it. Libraries are just tools, not magic wands."

Too true. A large number of people coming into the #ajax channel on Freenode with questions are asking things like "My AJAX request won't work. I'm using Prototype. Can you help me?" These guys are server-side devs or C++ app developers who are being forced to use AJAX by their CTO or Marketing department or whatever, and want to just plop in a library and have it work.

And in many cases, it works fine. But when something goes south, these guys don't have the foggiest idea where to start troubleshooting. Usually, it's something like "Use a window.onload event listener to make sure your div has loaded before writing to it."

Libraries are of course a good use of abstraction, and sometimes are an indispensable tool for getting your work done. When the abstraction breaks down, however, it does really help to know what's going on inside. Joel Spolsky's Law of Leaky Abstractions has some good stuff to say about the ups and downs of using a black box to do stuff.

About

This is the blog for Matthew Eernisse. I currently work at Yammer as a developer, working mostly with JavaScript. All opinions expressed here are my own, not my employer's.

Related

Previous posts

All previous posts ยป

This blog is a GeddyJS application.