Tuesday, March 01, 2005

The problem with XMLHttpRequest()...

... exists in the fact that javascript is, and always will be, a single threaded beast. Async calls with xmlhttprequest() just plain won't work like they should without an incredible tangle. There's no easy way that I can see, nor that Harry Fuecks can either, to implement threads which are spun off every time a remote request is made.

A bunch of different approaches to this exist, but when it comes down to it, you're limited to a single request from start to finish.

You haven't noticed it, or cared, but with Gmail: You can only do one thing at a time. That's because it's all being run through a single transaction - as is everything on the web.

Actually, I stand corrected. If you load a webpage with images or stylesheets in it, your browser can successfully use queing and negotiation of http requests. Why can't we see some of this functionality exposed in javascript?

What we need is micro http transactions - but we don't have it. Not in javascript. What's a developer to do!

Also: Certain things are annoying!

Update: certain bugs have been resolved as of Firefox 2.0 which solve this problem.
Post a Comment