fs.js 377 B

12345678
  1. const fs = require('fs')
  2. const promisify = require('@gar/promisify')
  3. // this module returns the core fs module wrapped in a proxy that promisifies
  4. // method calls within the getter. we keep it in a separate module so that the
  5. // overridden methods have a consistent way to get to promisified fs methods
  6. // without creating a circular dependency
  7. module.exports = promisify(fs)