1.0.5 • Published 7 years ago

filehelper v1.0.5

Weekly downloads
2
License
ISC
Repository
github
Last release
7 years ago

filehelper

it is a npm package that provides fs function, with file existed check before file write.

NPM

Install

$ npm install --save filehelper

Usage

Writing a file:

  • replace the old one, while the file is existed
  • create new one, while the file is not existed
var filehelper = require("filehelper")

var str = ' I love Peter 3';

filehelper.write('./data.json', str)
    .then( res=> {console.log('file is created');})
    

Read a file:

var filehelper = require("filehelper")

filehelper.read('./data.json')
    .then( res=> {console.log(res)})
    

License

MIT © Waheng Chang

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago