Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

exit foreach loop js

['a', 'b', 'c'].every(function(element, index) {
  // Do your thing, then:
  if (you_want_to_break) return false
  else return true
})
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #exit #foreach #loop #js
ADD COMMENT
Topic
Name
5+3 =