Skip to content

Instantly share code, notes, and snippets.

@leewind
Last active August 29, 2015 14:05
Show Gist options
  • Select an option

  • Save leewind/9e050bb1ae4260a0cbca to your computer and use it in GitHub Desktop.

Select an option

Save leewind/9e050bb1ae4260a0cbca to your computer and use it in GitHub Desktop.
nodejs:fs.readFile
var fs = require('fs');
fs.readFile("debug/info.txt", {encoding:"utf8"}, function(err, data) {
if(err) {
console.log(err);
} else {
parse(data);
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment