From the discussion we had in comments, it looks like Chrome is using a with
statement to layer some of its own stuff over the top of window
properties. It probably does this because those properties would not normally be overwritable. The delay is most likely down to how soon Chrome can inject its own script into the UIWebView (browsers on iOS are forced to use the underlying UIWebView object rather than their own engines) after a page starts loading.
If all this speculation is actually true, then there's simple solution, other than to access window.a
instead of a
or take the power back and use your own with
statement:
with (window)
eval(myScript);
Hardly a solution anyone would relish implementing, but might be your only option.