html-truncate- A HTML truncator

Safe HaskellNone




truncateHtml :: StringLike str => Int -> str -> strSource

Truncate HTML, and ensure that tags are closed; Remove trailing empty tags

truncateHtml' :: StringLike str => Int -> str -> (Int, str)Source

truncateStringLike :: StringLike str => Int -> str -> (Int, str)Source

Truncate to full words. If actual truncation occured, remove the last (usually cut-off) word, then remove trailing whitespace. | Returns the truncated string and the number of characters that remain to be truncated