Skip to content

Instantly share code, notes, and snippets.

@Mayankgupta688
Created April 11, 2020 08:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Mayankgupta688/72d86b083a57824a5c5e69d52921bc08 to your computer and use it in GitHub Desktop.
Save Mayankgupta688/72d86b083a57824a5c5e69d52921bc08 to your computer and use it in GitHub Desktop.
Node Streams
var fs = require('fs');
var fileReadStream = fs.createReadStream('./largeFile.html');
fileReadStream.on('data', function(chunk) {
console.log("Reading In Progress....")
console.log(chunk.toString())
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment