mirror of
https://github.com/hexastack/hexabot
synced 2024-12-26 22:02:48 +00:00
fix: after truncating add '...'
This commit is contained in:
parent
cdcfc2663d
commit
126e2494d4
@ -7,5 +7,5 @@
|
||||
*/
|
||||
|
||||
export const truncate = (text: string, length = 300) => {
|
||||
return text.length > length ? text.substring(0, length) : text;
|
||||
return text.length > length ? text.substring(0, length) + "..." : text;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user