JavaScript fs.readFile function
ajayprashar (1)

Hi,
My name is Ajay and I am new to JavaScript. I have a question I was hoping you could help me with:

How do I access the function 'fs.readFile' from within node within repl.it?

import fs from 'fs';

let ourStuff = fs.readFile('G:\DATA\git\ipromise\ipromise.txt','utf8', callback);
console.log(ourStuff);

Thank you,
Ajay

You are viewing a single comment. View All
Answered by eankeen (758) [earned 5 cycles]
View Answer
ajayprashar (1)

@eankeen Thanks for the great reply. I will try your advice right now.