initialization - when does javascript initialize vars? -
var x = ["aaa", "bbb", "ccc", ...]; function f() { var y = ["aaa", "bbb", "ccc", ...]; }
it big array, @ least in opinion.
i assume y
gets initialized again @ every instance.
would global x
initialized 1 time when page loaded? seems reasonable...
yes (+27 chars satisfy so!)
Comments
Post a Comment