SHARE
TWEET

Untitled

a guest Apr 24th, 2019 67 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. const fs = require('fs');
  2.  
  3. const myReadFile = async function(filename) {
  4.     тут создать промис и использовать fs.readFile
  5. }
  6.  
  7. const promise = myReadFile('./some.txt');
  8. promise.then(function(content) {
  9.  
  10. })
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top