Stopping a forEach loop


#1

Currently there is no way to abort the iteration of a forEach loop.

In jquery, if the callback function returns false the loop will stop. (http://api.jquery.com/each/ and search for: “You can stop the loop from within the callback function by returning false.”)

What do you guys think?


#2

If you’re trying to break on the first condition that is true, there is always Ember.Enumerable.html#method_find