Back in the day, I was a big fan of ARP and developed my own framework based on ARP and Cairngorm at a company I worked for, which was pretty cool. But I’ve gotten a bit rusty lately. Working at Brightcove for a couple years on pre-existing apps and code kind of stagnated me a bit. So recent large apps I’ve built have gotten a bit messy. For a project I’m working on now, I definitely needed a lot more order, so started looking into this stuff again.
I’m lucky enough to work with some smart fellas – Todd Anderson, who’s done a lot of Flex and Cairngorm stuff (he’s always throwing commands into my projects), and Joe Berkovitz, who his own framework up on Adobe Developer Center.
I also got to do a bit of work with Cairngorm in Flex a few weeks ago. Unfortunately, my current project is AS3 only (well, that’s not unfortunate in itself, but it means I can’t just use Cairngorm straight up in it). But I did start replicating some aspects of it for use in the project – the Event Dispatcher, Commands and Front Controller. It definitely helps in keeping the main class simpler and less tightly coupled with the various parts of the app. The one thing that’s hard to implement, though, is the fact that Cairngorm makes heavy use of DataBinding between views and models. Since DataBinding is Flex only, I’m making my model extend EventDispatcher to be observable. But now I have two different event models in the app, which is kind of smelly.
I guess next up I’ll take a look at MVCS (or I could just walk over to Joe and ask him about it) and Pure MVC.