Got a bug report on emoji-picker-element that it's super slow if you have ~20k custom emoji (some fediverse instances… 😵💫). I was about to write some complex virtualization logic until I remembered that `content-visibility` exists: https://web.dev/articles/content-visibility
~15% perf boost in Chrome, ~5% in Firefox, Safari has it in Tech Preview I guess. And no accessibility pitfalls or complicated code to maintain. Not as good as virtualization, but amazing what a few lines of CSS can do. https://github.com/nolanlawson/emoji-picker-element/pull/445
Working on an additional PR now that adds a _bit_ more complexity but gains a ~15% perf boost in Chrome and ~36% in Firefox. It relies on detecting when the `content-visibility: auto` state changes and using the old `<img data-src>` trick to set the `src` in that case. https://github.com/nolanlawson/emoji-picker-element/pull/449
A bit of extra code, but still not as gnarly as a full virtual list!