Skip to content

Instantly share code, notes, and snippets.

@Xedii Xedii/node-async.js Secret
Created Dec 28, 2018

Embed
What would you like to do?
const main = async inputFile => {
const readStream = fs.createReadStream(inputFile, { encoding: 'utf8' });
for await (const line of readStream) {
console.log(line);
}
console.log('SUCCESS!!');
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.