ZiadJ / knockoutjs-reactor

Recursively tracks changes within a view model no matter how deeply nested the observables are or whether they are nested within dynamically created array elements.
Other
74 stars 22 forks source link

add support for a custom getter function #23

Closed jrsearles closed 9 years ago

jrsearles commented 9 years ago

I kept the signature similar to the other callbacks.

Fixes #16

ZiadJ commented 9 years ago

Thanks for this one! However I'll probably change the name of the getter function to something more descriptive like 'beforeWatchNode'. Another possibility is to merge it with the existing 'beforeWatch' function, by placing it higher up in the order of execution, such that it accepts both observables and nodes. Not sure yet which one is the better way to go. Feel free to share your thoughts on it.