
How JavaScript works: the rendering engine and tips to optimize its performance - zlatkov
https://blog.sessionstack.com/how-javascript-works-the-rendering-engine-and-tips-to-optimize-its-performance-7b95553baeda
======
Klathmon
This is somewhat off-topic, but has anyone here used SessionStack?

How well does the service work, and is there a noticeable performance impact
for the software to record on mid-range mobile devices?

It looks really interesting and would probably be really helpful, but I can't
include anything else in our applications that will further tax our already
struggling lower-end devices with more code that needs to run and more data
that needs to be transmitted.

~~~
benthehenten
I'm not sure about the implementation in Session Stack, but I work at
LogRocket ([https://logrocket.com](https://logrocket.com)) where we're solving
a similar problem. We use a few methods to ensure that we have a minimal
overhead on performance.

\- We use worker threads for data encoding and network I/O

\- We use the MutationObserver API for capturing diffs of the DOM

\- We pull static resources directly from an application's servers (vs
uploading from the client)

\- Loading method shims first (and later the rest of our SDK asynchronously)
to reduce initial loading time

\- Batching requests and waiting for network downtime to send data

\- We use Protobufs as a wire format for reducing bandwidth

I'm sure Session Stack employs some similar techniques- would be curious to
hear about methods they're using as well.

~~~
sonaltr
> \- We use worker threads for data encoding and network I/O

Is this open sourced? I would like to understand how this works? (how do you
capture network i/o?)

------
LoSboccacc
-

~~~
dahart
It's called "layout" in the article, and it's reasonably well represented.

