Skip to content

Instantly share code, notes, and snippets.

@BRELID
Created July 24, 2019 11:53
Show Gist options
  • Save BRELID/e9beeaf014e9b9973fb646b620b9d51f to your computer and use it in GitHub Desktop.
Save BRELID/e9beeaf014e9b9973fb646b620b9d51f to your computer and use it in GitHub Desktop.
Writing Files With NodeJS
var fs = require("fs");
var data = "New File Contents";
fs.writeFile("temp.txt", data, (err) => {
if (err) console.log(err);
console.log("Successfully Written to File.");
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment