WordCount.js is a client-side JS and Node.js library that counts bytes, words, lines, chars, and calculates the longest line of a file using the HTML5 File API.
When a file is uploaded using the file input element with the given input selector then the number of bytes, words, lines, chars, and the longest line in the uploaded file are calculated and then callback is called.