From 44ff87b12adf48f3f850be2eae6a2ea78f7778e9 Mon Sep 17 00:00:00 2001 From: JP Richardson Date: Thu, 31 Jan 2013 15:46:15 -0600 Subject: [PATCH] Getting rid of readTextFile(). --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 61853e0..bb507c4 100644 --- a/README.md +++ b/README.md @@ -202,6 +202,11 @@ fs.outputFile(file, 'hello!' function(err) { ### readTextFile(file, callback) +**NOTE:** This was a mistake. Don't use this method. It will be removed. The problem with this method +is that when a developer reads your code `readTextFile()` causes an additional cognitive load on trying to +figure out what it does. Where as most Node.js devs will know what `readFile(file, 'utf8', callback)` does. +Plus, `readTextFile()` is ambigious. DON'T USE IT. + Exactly the same as `readFile(file, 'utf8', callback)`. Sync: `readTextFileSync()`.