Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

stdi nodejs


process.stdin.on('readable', () => {
	let chunk
	// Use a loop to make sure we read all available data.
	while ((chunk = process.stdin.read()) !== null) {
		process.stdout.write(`data: ${chunk}`)
	}
})
 
PREVIOUS NEXT
Tagged: #stdi #nodejs
ADD COMMENT
Topic
Name
8+2 =