Lightpanda headless browser written in Zig

15 pointsposted 10 hours ago
by zlu

1 Comments

eatonphil

4 minutes ago

I have a research folder of some findings comparing Chrome, headless-shell, lightpanda, jsdom, etc. Lightpanda still did quite well, though with much smaller multiples compared once you've mildly tuned Chrome/headless-shell, but it crashed more often than Chrome and headless-shell.

I haven't yet had time to write it up on The Consensus. So here are some findings you can take or leave.

  Configuration                       CPU s  Mem MiB  Median  Matched  Errors
                                      /page   (peak)    page  (of 40)
  Chrome, default flags                2.31    1,229    4.4s      ref       0
  Chrome, tuned                        1.98    1,244    3.1s       40       0
  Chrome, tuned + block all trackers   1.31    1,338    2.2s       37       0
  headless-shell, today's settings     2.30      748    3.9s       39       0
    + stop at network idle             2.16      772    2.6s       39       0
    + block ads/analytics              1.79      748    2.1s       39       0
  headless-shell, tuned                1.67      723    2.1s       39       0
  headless-shell, tuned + no frames    1.29      696    1.9s       39       0
  headless-shell via Playwright        2.58      805    4.2s       38       0
  Firefox via Playwright               6.94    2,270    5.6s       38       0
  WebKit via Playwright                4.76    4,125    5.2s       36       0
  Lightpanda, default                  1.31      540    3.6s       35       4
  Lightpanda, tuned                    1.04      509    1.3s       35       4
  jsdom                                2.66    2,102    4.3s        4       8
  Plain HTTP fetch, no JS             0.002       97   0.05s        0       0