Reading and Writing File Data in NodeJS

https://youtu.be/vm7vxkyx4HE?si=sH3ZcLwNhidJzlhz const fs = require('fs'); const line = "Writing this text to a file"; //fs.appendText fs.writeFile('myfile.txt', line, err => { if (err) throw err; console.log('text to a file.'); }); fs.readFile('myfile.txt',…

How to Add Static Methods to a Class in JavaScript

https://youtu.be/M5BYcF3IGNM?si=h6lqaLSLXS2nSgtF class Book { constructor(isbn, title, author, publishedDate) { this.isbn = isbn; this.title = title; this.author = author; this.publishedDate = publishedDate; } static booksEqual(book, book2) { if (book instanceof Book…