My javascript testing toolchain

Update (Jan 4th 2014): Since I wrote this post, I’ve switched to using Karma instead of testem. Karma is written and supported by the Angular guys and in the year or so since this post was originally written has matured more than testem. I have a karma skeleton project that I use to setup my frontend testing environment. The readme for that project is pretty extensive and outlines how to set up a karma project.

Creating js files with Rhino (from JSON)

(This is primarily a note to myself) I’ve been playing with Rhino. Specifically, reading in json objects, turning that into normal, runnable objects and saving that to a file so browsers can run it. More specifically, the code that transforms the JSON to an object in the browser should be exactly the same as the one that runs in Rhino. That way I don’t have to maintain two different versions.

ActsAsUndoable

With web apps becoming more and more like Desktop apps, it seems like user interfaces need be more like desktop user interfaces too. Some of these web apps can have a complex UI and their users need to be able to feel comfortable with it. Of course, making the UI as simple as possible is key, but if a task is relatively complex then the UI will also be relatively complex.

AjaxEvent

Tim Huegdon has a great post about a really rather sweet piece of code called AjaxEvent over at his site, nefariousdesigns. Developed with Mark Aidan Thomas, AjaxEvent is an object that wraps around the YUI Connection and CustomEvents that makes managing multiple, distinct ajax calls really easy.

Another Tabbed Interface

This is a rather belated post and is sort of a continuation of my last post about Aspect Oriented Programming. I’ve made yet another tabbed interface widgety thing (like the ‘tubes needs another one) that uses AOP to add additonal features. A tabbed interface widget provided a nice problem for me to experiment with AOP. You can see the results which allows tabs in a widget to be draggable and closeable too.

JS Fun

For the last few months I’ve been playing around with different design patterns and methodologies in Javascript. I’ve been looking at the Composite pattern and also Aspects Oriented Programming (AOP). AOP is a way of changing the behaviour of existing code without modifying it. It does this by providing, what AOP calls, advice at certain join points. In plain english, it provides a way of adding additional behaviour (advice) at certain points in your program (join points).

Howdy..

Hey. It’s been a while. Been busy with work, life and stuff. But feel like posting again so I’ve changed servers and got a temp design up, which will change soon. So let’s see what happens.

Another LiveInfo fix

Andrew Gregory reported some bugs in Opera 7.54u2. The bug in Opera 7.54u2 turned out to be rather strange. Any opera browser below 7.6 uses an iframe and I check the html within the frame to see if it is loaded. I use the text as that is the root node. In 7.54u2, there is no , only . Strange. Anyway I introduced a check for that and it works okay now.

LiveInfo Update

Just a minor update release on LiveInfo. Version 1.01 just tidies up some Javascript warnings that sometimes occur.

Semantic Web - right now

A semantic interface means finding information online will be much easier as unrelated results won’t appear. Here’s a gentle intro to the semantic web. The semantic web won’t be in wide use yet but the University of Southhampton has released an interface to a new semantic web interface called mSpace. They have an example interface searching for classical music which currently is Mozilla only. It is javascript driven and uses xmlhttprequest to retrieve the data.