Files
sohan-salehnia/src/lib/format.ts
T
Alireza HassaniandCursor 11fd1cf454 Connect Meshkee catalog, customer login, and SEO sitemap config.
Wire products and articles to the public API, send guests to the customer portal, and publish sitemap-config for Meshkee nginx.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-09-03 09:31:15 +03:30

6 lines
209 B
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
const FA_DIGITS = ["۰", "۱", "۲", "۳", "۴", "۵", "۶", "۷", "۸", "۹"];
export function toFa(value: number | string): string {
return String(value).replace(/[0-9]/g, (d) => FA_DIGITS[Number(d)]);
}