Countable is a JavaScript function to add live paragraph-, word- and character-counting to an HTML element. Countable does not rely on any libraries and is very small in size.
Download on GitHubnew Countable(area, function (counter) {
results.paragraphs.textContent = counter.paragraphs;
results.words.textContent = counter.words;
results.characters.textContent = counter.characters;
results.all.textContent = counter.all;
});