bitovi/canjs — pull request #318 by daffl (2013-03-15 13:52:05+00:00)
Title: Allow dots in Observe keys

I already merged this fix into the [1.2 develop](https://github.com/bitovi/canjs/tree/develop) branch with #309 but suggest to make this part of the 1.1.5 release as well since all tests are still passing the same and it doesn't introduce a new API. The fix makes this possible:

```js
var ob = new can.Observe();

ob.attr('a.b', 'test');
ob.attr() // -> { a: { b: 'test' } }

ob.attr({
'a.b': 'test'
});

ob.attr() // -> { 'a.b': 'test' }

ob.attr('a.b')
// will look for 'a.b' first
// and then for ob.attr('a').attr('b')
```

Since `new Observe({ 'test.key': 'value' })` failed before, introducing the direct key lookup for `obsreve.attr('test.key')` (and falling back to the nested property lookup if it doesnt' exist) shouldn't pose a problem for any existing functionality. Fixes #257 and #296.