Node.js Core modules and the dealing with files
Node.js is not a web framework, but rather a whole execution environment as we have already mentioned before. That means that it contains also modules that deal with files, talk to databases, collect data from microcontrollers and more.
So how is it possible to read and/or write data from and into a file with node.js. The answer is simple. Through the fs core module that Node.js natively provides. All we need to do is to import the module into our script and make use of the function the module provides.
During the next chapters we will focus on the basic functions, reading from a file, writing to a file, the synchronous and the asynchronous way. But then if you would like to learn more (how to rename or delete a file programmatically, change permissions and more) you are very welcomed to read the official node.js fs module documentation (this is for the version 10.16.0).