read text file and display in html using javascript code example
Example: read text in txt file js
const fs = require('fs')
fs.readFile("File.txt", (err, data) => {
if (err) throw err;
console.log(data);
})
const fs = require('fs')
fs.readFile("File.txt", (err, data) => {
if (err) throw err;
console.log(data);
})