What is appendfile() function? We can also use the fs module to append the content using appendFile function into a file. However, appendFile function will create the file if the file doesn’t exist or append the content into the file, if the file already existed. Let’s create a folder structure […]
How to list directory files?
Node.JS also contains module that allows us to communicate with the file system. The FS module can be used to list files in directories, create new files in directories, stream files, video files, modify files permissions and etc. Here we have two ways to read the content of directory synchronously, […]