propapier/app/utils/number.ts
webfussel 11bcdce6cb add: new list layout design
New design, custom uuid, better handling of swipe
2025-05-10 13:32:28 +02:00

5 lines
No EOL
285 B
TypeScript

export const replaceComma = (value: string | number) => `${value}`.replace(',', '.')
export const clamp = (value: number, min: number, max: number) => Math.min(Math.max(value, min), max)
export const between = (value: number, min: number, max: number) => value >= min && value <= max