puzzle-rain
puzzle-rain copied to clipboard
Progressively load assets on as-needed basis
In App.js
all of the modules are imported at the same time, which consequently fires off a bunch of XHRs for models, audio, textures, etc - all the assets.
This results in a grand total of 193 HTTP requests at once. That enough XHRs on the main thread is enough to crash most low-end machines, especially mobile devices (which I understand is not our target); it's just something worth mentioning.
Culprit of issues #77 and #86. But, the main one was blocking on audio loading. This can come as an enhancement much later.
https://github.com/mrdoob/three.js/issues/4248#issuecomment-125244327 has some good concepts.