I\'m creating an updater that downloads application files using the Node module request. How can I use chunk.length to estimate the remaining file
request
chunk.length
This should get you the total you want:
req.on( 'response', function ( data ) { console.log( data.headers[ 'content-length' ] ); } );
I get a content length of 9404541
9404541