Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Thanks!

What's super neat here is that I didn't have to build that. The WASI standard defines `fd_fdstat_get` which tells the binary the type of the file descriptor. For stdin/stdout/stderr I return that it is a "Character Device" (https://github.com/taybenlor/runno/blob/main/packages/wasi-m...). QuickJS understands that means it's running in a TTY and so it emits all the right characters to do colouring. XTerm.JS then interprets those characters and displays the appropriate colours.



Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: