Skip to content

Instantly share code, notes, and snippets.

@itayw
Created October 31, 2013 17:20
Show Gist options
  • Save itayw/7253495 to your computer and use it in GitHub Desktop.
Save itayw/7253495 to your computer and use it in GitHub Desktop.
nodejs - simple write to file
var fs = require('fs');
fs.writeFile("/tmp/test", "Hey there!", function(err) {
if(err) {
console.log(err);
} else {
console.log("The file was saved!");
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment