How to use the write.promise function in write

To help you get started, we’ve selected a few write examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github jonschlinkert / write-json / index.js View on Github external
writeJson.promise = function(filepath, value) {
  var args = [].slice.call(arguments, 1);
  return writeFile.promise(filepath, stringify.apply(null, args));
};

write

Write data to a file, replacing the file if it already exists and creating any intermediate directories if they don't already exist. Thin wrapper around node's native fs methods.

MIT
Latest version published 5 years ago

Package Health Score

71 / 100
Full package analysis

Popular write functions