2
0
Files
bot/packages/variables/isSingleVariable.ts
2024-06-24 15:03:18 +02:00

6 lines
172 B
TypeScript

export const isSingleVariable = (value: string | undefined): boolean =>
!!value &&
value.startsWith('{{') &&
value.endsWith('}}') &&
value.split('{{').length === 2