{"size": 457, "ext": "js", "max_stars_repo_path": "asynchronous.append.js", "max_stars_repo_name": "jg925/managing-files-with-nodejs", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "asynchronous.append.js", "max_issues_repo_name": "jg925/managing-files-with-nodejs", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "asynchronous.append.js", "max_forks_repo_name": "jg925/managing-files-with-nodejs", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 24.0526315789, "max_line_length": 82, "alphanum_fraction": 0.5579868709}
const { writeFile, appendFile } = require("fs");

/* writeFile(
  "./data/app.log",
  '163.3.217.18 - - [21/09/2019:10:07:21 -0500] "GET /write-file-test" 405 21512',
  { flag: "a" },
  (err) => {
    err ? console.log(err) : console.log("file saved!");
  }
); */

appendFile(
  "./data/app.log",
  '163.3.217.18 - - [21/09/2019:10:07:21 -0500] "GET /write-file-test" 405 21512',
  (err) => {
    err ? console.log(err) : console.log("file saved!");
  }
);
