I was looking at source code of Ext object in ExtJs docs here and I noticed this for loop:
for (j = enumerables.length; j--;) {
k = enumerables[j];
if (config.hasOwnProperty(k)) {
object[k] = config[k];
}
}
So, normally in a for loop, we have do initialization, specify condition and then increment/decrement the counter. I do see an initial condition and j-- which decrements the counter after each iteration. However, what I can't figure out is how is the loop going to be terminated? I neither see any condition nor a break keyword that will terminate the loop.
What am I missing here?