Disable input handling in a non-tty environment
See original GitHub issue/node_modules/ink/index.js:61
Never seen this one before and googling didn’t help much - what’s going on here? It’s preventing me from running this example from your docs:
`const {h, render, Component} = require(‘ink’);
class Counter extends Component { constructor() { super();
this.state = {
i: 0
};
}
render(props, state) {
return `Iteration #${state.i}`;
}
componentDidMount() {
this.timer = setInterval(() => {
this.setState({
i: this.state.i + 1
});
}, 100);
}
componentWillUnmount() {
clearInterval(this.timer);
}
}
const unmount = render(<Counter/>);
setTimeout(() => { // Enough counting unmount(); }, 1000);`
Issue Analytics
- State:
- Created 6 years ago
- Comments:9 (7 by maintainers)
Top Results From Across the Web
Error "The input device is not a TTY" - Stack Overflow
For docker-compose users, I wanted to add that I had a similar command to run - I wanted to delete redis keys based...
Read more >Stop bash subshell when parent wants tty input
What I would like to have happen is that when wrapper wants to read from the terminal, the child process is suspended, and...
Read more >Inputs on an Embedded Linux Device | Qt 6.4
On application startup, EGLFS and LinuxFB attempt to disable the terminal keyboard by setting the tty's keyboard mode to K_OFF . This prevents...
Read more >TTY | Node.js v19.3.0 Documentation
When in raw mode, input is always available character-by-character, not including ... by the terminal is disabled, including echoing input characters.
Read more >Xorg - ArchWiki
The X.Org Foundation is the educational non-profit corporation whose ... To block tty access when in an X add the following to xorg.conf:...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Fixed via #42. Will close the issue when a release is out.
Released
0.4.0
, sorry for the delay.