got frontend working with backend project
This commit is contained in:
3
frontend/lib/truncate.ts
Normal file
3
frontend/lib/truncate.ts
Normal file
@ -0,0 +1,3 @@
|
||||
export const truncateString = (str: string, maxLength: number) => {
|
||||
return str.length > maxLength ? `${str.slice(0, maxLength)}...` : str;
|
||||
};
|
Reference in New Issue
Block a user