rviscomi / trunk8

jQuery Truncation Plugin -- THIS PROJECT IS NO LONGER MAINTAINED
MIT License
703 stars 95 forks source link

word boundary feature #42

Closed cltrudeau closed 9 years ago

cltrudeau commented 10 years ago

example:

$('too-long').trunk8({ wordBoundary:' -', });

The above would use space or hyphen as a word boundary and after the bite search is run backs the string up until it finds a boundary character.

rviscomi commented 9 years ago

Concerned about adding another O(n) operation. Also, code needs to match existing formatting conventions to be merged.