EDIT: Liftoff isn't showing any website/url previews for the links in the post or comment text but it's working for primary URLs of posts so it's better than nothing lol
EDIT2: Actually Liftoff doesn't do anything more than Jerboa already does. It seems Boost can show URLs before opening a link but it is closed source.
It looks like kbin does check for and validate these. It hands back an "invalid URL" error if the mentioned javascript: schema in the bug report for lemmy is used.
EDIT: Though I didn't try submitting to a lemmy instance and seeing whether kbin validates links coming in from federated systems rather than locally-submitted.
EDIT2: Honestly, this should be checked in clients too to avoid a malicious server they connect to directly feeding them XSS URLs. Like, probably warrants bug reports for all clients.