lauripiispanen / angular-bacon

Angular-bacon.js bindings
MIT License
146 stars 16 forks source link

Add support for `$watchCollection` #6

Closed theefer closed 10 years ago

theefer commented 10 years ago

angular-bacon currently always uses $watch, which does not work for Arrays of Objects. Should we add a $watchCollectionAsProperty method that would use $watchCollection under the hood?

I'm happy to give this a go in a PR if it sounds sane.

Note that the Array or Object would still be treated as a single atomic value for the Property.

lauripiispanen commented 10 years ago

Sure, sounds good to me. Granted, someone might argue that the name does feel a bit longish, but I think it's still it's consistent with both the angular and angular-bacon APIs. Just shoot a PR and let's make it happen!