Note that Lazarus isn't (yet) able to do web-based GUIs. Free Pascal only just added wasm support (not in a release yet, but it is part of the main branch), so all is needed (which TBH is kind of a big "all" :-P) is someone to make an LCL backend for it, so it might happen at some point.