nodejs.dev icon indicating copy to clipboard operation
nodejs.dev copied to clipboard

Update index.md

Open matveisch opened this issue 3 years ago • 3 comments

Description

Since node 10, it is mandatory to pass a callback on fs.writeFile(). Otherwise the method does not work.

matveisch avatar Jul 15 '22 10:07 matveisch

I'm not sure it is mandatory? Small example here: https://stackblitz.com/edit/node-rvjjyr?file=index.js

mikeesto avatar Jul 16 '22 01:07 mikeesto

Well, yeah, we can do that, but the code from the docs doesn't work. So i guess it does need fixes

matveisch avatar Jul 16 '22 07:07 matveisch

This callback is not mandatory, as @mikeesto explained. Could you please give an example of where you're facing this issue?

ovflowd avatar Jul 29 '22 22:07 ovflowd

Closing this PR as it sounds abandoned.

ovflowd avatar Aug 12 '22 14:08 ovflowd