Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Functions in bindings seem to be called twice #174

Closed
robdodson opened this issue Jul 18, 2014 · 3 comments
Closed

Functions in bindings seem to be called twice #174

robdodson opened this issue Jul 18, 2014 · 3 comments

Comments

@robdodson
Copy link

Looking at this example:
http://jsbin.com/niteta/6/edit

The sublist function is always called twice, regardless of what it actually does or returns.

@sjmiles
Copy link
Contributor

sjmiles commented Jul 19, 2014

Just a note that this appears to be an issue with filters generally. It happens whether using pipe or function syntax.

@nevir
Copy link
Contributor

nevir commented Jul 28, 2014

Interestingly, and seemingly related: we're binding to the output of that function, which seems like it has the potential to be severely confusing: http://jsbin.com/koviji/1/edit

Should it be binding at all? Seems like it should be binding, at most, to the function itself (too magic otherwise?).

@sjmiles
Copy link
Contributor

sjmiles commented Jul 30, 2014

@jmesserly or @ajklein ... maybe you can review? Seems good to get this fixed asap.

jmesserly pushed a commit that referenced this issue Jul 31, 2014
fixes #174 -- minimize calls to discardChanges for if/bind/repeat
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants