BetterChat_new / src /lib /utils /trimPrefix.ts
BetterAPI's picture
Duplicate from BetterAPI/BetterChat
166a6c0
raw
history blame contribute delete
150 Bytes
export function trimPrefix(input: string, prefix: string) {
if (input.startsWith(prefix)) {
return input.slice(prefix.length);
}
return input;
}