showing results for - "how to detech ctrl 2bc exist in nodejs"
Glenys
10 Nov 2020
1export const detectKeyboard = () => {
2	process.openStdin().on('keypress', function (_, key) {
3		if (key && key.name === 'c' && key.ctrl) {
4			deleteData()
5			process.exit()
6		}
7	})
8}
9