RadLikeWhoa / Countable

Add live paragraph-, word- and character-counting to an HTML element.
https://sacha.me/Countable
MIT License
1.64k stars 134 forks source link

Countable doesn't count newlines #20

Closed halfdan closed 10 years ago

halfdan commented 10 years ago

Countable does not seem to recognise newline characters (line feed / carriage return). If this is intentional, I would like to suggest a new option to optionally enable counting newline characters as well (which are currently omitted in https://github.com/RadLikeWhoa/Countable/blob/master/Countable.js#L190).

Related: https://github.com/TryGhost/Ghost/issues/1432

I'm happy to provide a PR.

RadLikeWhoa commented 10 years ago

I see the issue and it's definitely something I haven't put too much thought into. I'll consider how to move on with this and I'll get back to this ASAP.

RadLikeWhoa commented 10 years ago

This issue is resolved on Countable's side. Further discussion in this issue: TryGhost/Ghost#1432

halfdan commented 10 years ago

Thanks a lot!