fs.writeFile
Method fs.writeFile() writes data to a file, replacing the file if it already exists.
Syntax
fs.writeFile(filePath, data)
Parameters
filePath
Absolute or relative path to the file (string)
filePath
File contents (string)
Return value
null or string error's description.