Read part of file.
Meh. Read part of file. Mostly because current way of doing it is too cumbersome.
$ npm install partoffile
Function takes 4 parameters :
- path to file you want to read
- position from where to start reading
- position till where to read
Callback gets a buffer which can be used however.
var file = require'partoffile';file'test.txt' 0 10iferr throw err;console.logbuffertoString'utf8';;