I would guess that you're using Wasm for this. If it's not a secret, can I ask which Wasm libs you're using?
I'm afraid can't help with the libs then ;)
I'd like to have more functionality in-browser, though, like an LSP running as a worker in the background. Do you have any materials that I could read about it or something like that?