Hacker News new | ask | show | jobs
by Gshaheen 507 days ago
I too am obsessed with beautiful TUI apps. I would love to see them inside a browser to lower the barrier to entry for the majority of folks. Almost like an emulated terminal inside the browser that’s simply accessed by url.

Are there any frameworks or examples of this being done?

2 comments

Not sure but https://angband.live/ lets you play Angband (a purely terminal game) in the browser, or watch other people play it live, which is kind of neat
ssh in the browser + self-hosting is usually all you need.
browser terminal + ssh + self hosting!

I’ve not looked into this is years but I once had this idea that in browser terminal and I remember discovering there exists javascript xterm implementation.

For me though I was thinking the setup needs custom MFA security since public browsers or devices can be compromised. Haven’t researched yet how to somehow add that to the access.

If it worked how I’d imagine you can just walk up to any computer with a modern browser, go to your self-hosted IP, it sends you access code to phone, or uses authenticator or rsa token, something, and you get your terminal access.

I currently host an ssh-only game that logs you in based on your github user. Ie: ssh withinboredom@my-game and it looks your keys up at github.com/withinboredom.keys ... then uses that as the authorized keys (this is all built-in to ssh btw).

It wouldn't be too difficult to extend this to support webauthn/passkeys via a little bit of magic.

Actually... that sounds like a pretty interesting project.

I was thinking more completely self contained. Did some research and seems it might be possible with xterm + webcontainer.