Closed neugierige closed 7 years ago
code snippet should read:
const readJSON = function (filename) { return new Promise((resolve, reject) => { fs.readFile(filename, { encoding: 'utf8' }, (err, res) => { if (err) { reject(err); } else { resolve(res); } }); }) .then(JSON.parse) };
@payne-chris-r
code snippet should read:
@payne-chris-r