Performance Improvements
-
perf: revert custom
composedOffsetParent
polyfill (#1894)Unfortunately, the platform provides no
composedOffsetParent()
method and this internal polyfill was causing a performance degradation. As a result, it is now opt-in.Ideally, the DOM layout where the issue arises should be avoided to begin with. However, if it can't be avoided, the default
platform
object is now exported so you can spread in all the other methods then write your own singlegetOffsetParent
hook that has the polyfill. You might want to add your own custom flags to turn it on/off when it's considered acceptable in a given scenario perf-wise.