What does HackerNews think of ink?

🌈 React for interactive command-line apps

Language: TypeScript

#1 in React
#23 in JavaScript
#5 in React
You get the comfort of using react components instead of fighting with HTML tables to make your emails look nice. I think it's awesome! It's analog to what ink[0] does with CLI outputs. Sure, you could write fancy CLI outputs in bash, but ink takes the pain out of it and makes it easy.

[0] https://github.com/vadimdemedes/ink

Using the Web Platform and using React are not opposites, you can do both. See: Remix as a framework that bakes in these ideas, but using the platform is easily achievable yourself too.

Making this distinction between HTML

s and React shows a clear misunderstanding of the programming model that React provides. It targets the platform in a native way. This is how React DOM, React Native, and libraries like Ink[1] work.

[1] https://github.com/vadimdemedes/ink

Interesting other library - React for the terminal. Allows you to build the UIs using familiar web techniques and even has react dev tools!

https://github.com/vadimdemedes/ink

The most modern terminal GUI (as for 2021) would have to use React: https://github.com/vadimdemedes/ink
The same single direction data flow/declarative render model as you’d use for DOM! The most prominent example is Ink: https://github.com/vadimdemedes/ink
This and other JS CLI libraries are typically used by JS projects that have tooling. Like when create-react-app scaffolds a project and asks you questions to customize it, etc. it's using libraries like this one. For a JS project it's just an easy npm install away as a dependency, and you know your users will have nodejs anyways.

Speed rarely matters for imperative user-facing tools. You're going to be waiting for a user to type and respond far, far longer than making some system calls to write to the shell.

Ink is a more interesting and maintained library to consider though: https://github.com/vadimdemedes/ink It lets you write react-like apps that output to the terminal instead of HTML.

There's `blessed` [0], a plain JS lib similar to `ncurses`. There's also `react-blessed` [1], which is a React renderer that targets `blessed` as the display layer, and `ink` [2], which is also a text-based React renderer but using its own display layer.

[0] https://github.com/chjj/blessed

[1] https://github.com/Yomguithereal/react-blessed

[2] https://github.com/vadimdemedes/ink

Theres ink: a TUI in react, there are others I believe too. https://github.com/vadimdemedes/ink
https://github.com/cronvel/terminal-kit

This is the one that most catches my attention.

Currently actively maintained plus it has something analagous to a document object model https://github.com/cronvel/terminal-kit/blob/master/doc/docu...

Also Ink is incredibly interesting as it enables ReactJS for creating TUI apps - mind bending!

https://github.com/vadimdemedes/ink

I can imagine the things above being combined with a sandbox plus Fabrice Bellard's QuickJS https://bellard.org/quickjs/ into a new type of application ..... the "pure text mode browser".

A "pure text mode browser" would not be designed to render ordinary HTML web pages, but would instead be a minimal browser designed only for text mode.