Method | Description | |
---|---|---|
Truncate ( this text, int maxLength = 30, string ommision = "...", string separator = "" ) : string |
Truncates a given text after a given length.
|
Method | Description | |
---|---|---|
ApplySeparator ( string text, string separator ) : string |
public static Truncate ( this text, int maxLength = 30, string ommision = "...", string separator = "" ) : string | ||
text | this | |
maxLength | int | Length of truncated text (default is 30) |
ommision | string | The last characters to be replaced with if truncated. (defaults to "..."). |
separator | string | Include if you want to truncate text at a natural break. For example, " " will truncate at word boundaries |
return | string |