truncateWords
Обрезает строку до указанного количества слов.
truncateWords
Сигнатура
typescript
function truncateWords(str: string, count: number, suffix?: string): stringПримеры
typescript
import { truncateWords } from 'strio'
truncateWords('The quick brown fox', 2)
// "The quick..."