Since JSOC is a standalone JavaScript module, incorporating JSOC into a Web development project is a matter of including a script reference, and working with common caching methods. Low-level methods are contained in the JSOC JavaScript module so that developers can focus on the Web development task at hand.

Yeah. That example code is pretty awful. It’s broken — it can’t do concurrency and it has no queue to protect it from itself. Example code like this shouldn’t be published, period. It makes the web stupider.

A very bloated way of stuffing the global scope full of junk, too. The example would be less horrible if it kept its object cache in its own JSOC singleton, though of course still not allow concurrent use by more than one consumer.

Well, I just looked at their 0.0.13 code that was released today. It’s not nearly as bad as before—they got rid of the accidental globals—but the code looks like it was written by somebody that is just learning JavaScript. A good 25% of the code consists of simple mistakes that an experienced JavaScript programmer wouldn’t make.

Now there’s nothing wrong with being a JavaScript beginner—obviously we all were at one time—but it’s quite a stretch to call this “a pluggable, extensible, open source client-side caching framework for JavaScript”.