I am using dotdotdot seems to bea cool plug-in... however, I need to use it an angular, is not working if new elements are loaded (via http.get <> ng-repeat)...
So I find that there is an angular-dotdotdot... How to use it? is not very clear...
Suppose I have the classical usage of dotdotdot like this:
// ellipsis body to 4 lines height
var ellipsis = $(".ellipsis-case-body");
var nrLines = 4;
var ellHeight = parseInt(ellipsis.css('line-height'), 10) * nrLines;
ellipsis.dotdotdot({ height: ellHeight });
// ellipsis title to 1 line height
ellipsis = $(".ellipsis-case-title");
nrLines = 1;
ellHeight = parseInt(ellipsis.css('line-height'), 10) * nrLines;
ellipsis.dotdotdot({ height: ellHeight });
How to use it with angular?
In their documentation
$scope.myText = 'some really long text';
Template:
<p dotdotdot='myText'>{{myText}}</p>
But how to set options?