Node.js fs createReadStream()

Description

Node.js fs createReadStream()


var fs = require("fs");

var readStream = fs.createReadStream('input.txt');

var writeStream = fs.createWriteStream('output.txt');

readStream.pipe(writeStream);/*from   w  w w.java  2s .  c  om*/



PreviousNext

Related