File System Module fs in Node.js | Node.js Core Modules | Read and Write File Synchronously Using fs

Опубликовано: 16 Октябрь 2024
на канале: Stubborn Developers
516
15

#stubborndevelopers

In this video, we will learn everything about file system core module (fs) of Node.js. To use any core module of node.js, we don't need to install it using NPM, we can just use it after require in our program.

fs (file system) module allows us to work with the file system on our system.

To include the File System module, we have to use the require() method:
const fs = require('fs');

Common uses of file system module are:

Create files
Update files
Append files
Read files as a string
read files as a Buffer Data
Rename files

*********** Node.JS Tutorial in English 2021 Playlist ***********
   • how to install node js  

*********** React.JS Tutorial in Hindi 2021 Playlist ***********
   • react js introduction in hindi