Remove unnecessary `requestAnimationFrame` callbacks in `Guest`
Profiling anchoring of large numbers of annotations in Chrome showed that there was significant overhead for scheduling and executing `requestAnimationFrame` callbacks. In the case of `Guest.anchor`, the callback often did nothing (it called `removeHighlights` with an empty array). There isn't a need for this any more AFAICS so just invoke the logic synchronously, which is much cheaper.
Showing
Please register or sign in to comment