This is a very old question now, but the answer is that the emscripten object you're getting is not a Javascript array, it's a special kind of vector object and you need to use get() to access the elements.