JS: loading textures on start up

ok….. last one(I hope.) I’m trying very hard to follow the
documentation here. I hope this isn’t something stupid because I
really feel bad asking for so much help.

the problem here, is that it takes 3 tries to get a texture loaded in
jit.js. in max it appears that jit.gl.texture makes max wait until
its done loading the file. but in javascript, it lets JS executing
the code. any work arounds for this?