Continued Chat UI Refactor

This commit is contained in:
Justin Ferrari
2022-11-11 22:03:58 -05:00
parent 5e4c5cf862
commit e145c9b0e1
5 changed files with 49 additions and 21 deletions

View File

@@ -0,0 +1,8 @@
export function cropAddress(string = "", range = 5) {
const [start, end] = [
string?.substring(0, range),
string?.substring(string?.length - range, string?.length),
//
];
return start + "..." + end;
}