toolkitchen/toolkit — pull request #126 by bsatrom (2013-05-10 21:29:36+00:00)
Title: Add custom date parsing module & Array deserialization support

There's a few things going on in this PR, so I'll break down the highlights. Let me know if I need to break these apart (if you want the date module, but not array support, etc.) of if I need to squash these into one commit.

1. Added support for Deserializing to Array from attributes, as per #124. I didn't get a yea or nay on this one, so feel free to let me know if its a silly idea you all don't want to support, but it would come in handy for the components I'm building.
2. Refactored the `deserializeValue` method in `attrs.js.` Things were starting to look a bit heavy with four types in the `switch,` so I factored the `switch` into a handler object, and cleaned things up a bit. FWIW, the handler object does perform a bit better than `switch` when running the tests on my machine.
3. Added a module for custom date parsing (`parseDates.js`) as per #119 and #122. This allows the deserializer to support dash and dot dates.

Once again, I know I crammed a few things in here, so let me know if I need to break things up to make life a bit easier on you all as you review and accept/reject.