Class-based JavaScript runs dramatically faster: calling a method through a list of objects is now many times quicker
This release makes one of the most common shapes in modern JavaScript much faster: looping over a list of objects and calling the same method on each. That pattern is everywhere - a component framework walking its elements, a game or physics loop stepping through its entities, a data grid rendering its rows, a scene graph visiting its nodes. Until now every such call took the browser's slow path: look the method up on the object, walk its class chain, then call it, once per item. Floati now learns the exact shape of the objects the first time the loop runs hot and compiles the call straight to native machine code, checking cheaply on each call that the object is still what it expects and instantly falling back if a page does something unusual. In a tight loop that calls a class method on each element of an array, the work now finishes many times sooner. As always the speed is proven: an independent check confirms the fast answer is identical to the slow one before it is trusted, and it all runs on your device.