I’ve been using the jQuery Ellipsis plugin on a few projects. However, on my latest one, I had the need to truncate text not on fixed heights, but a set number of lines.
I modified the plugin to do just that and threw it up on github. The Line Ellipsis plugin is still a work in progress, since detecting the size of a line is very unreliable. If you try it out and have problems, open a GitHub ticket. Or better yet, create a pull request.
Did you like this? Please share:
The Lost Year: A Failed Experiment to Switch Away From Mac
Fed up with the Apple Keyboard, I bought a ThinkPad, installed Linux, and promptly decided that I hated computers.
Maker's Space, Manager's Space
The Grand Remote Work Experiment: A Retrospective
The COVID-19 pandemic has lead to an unexpected experiment in remote working. What has worked and why?