/Wordcount.js

A simple Node.js application that counts all the unique words in all the files in a given directory.

Primary LanguageJavaScript

Wordcount.js

A simple Node.js application that counts all the unique words in all the files in a given directory.

Usage

Simply run it as follows:

run.sh DIRECTORY_WITH_FILES

And it will output results such as the following:

Results:

[ { word: '', count: 40906 }, { word: 'the', count: 11337 }, { word: 'and', count: 10822 }, { word: 'to', count: 8002 }, { word: 'of', count: 6116 }, { word: 'a', count: 5679 }, { word: 'i', count: 5657 }, { word: 'it', count: 4372 }]