Tarikh
Utilities

Digits

Convert numbers between English and Bangla digits without changing the surrounding text.

Start Here

Use digit helpers when you want to change the numeral system without changing the rest of the text.

Quick Rule

If only the digits should change, use toBanglaDigits() or toEnglishDigits().

Common Uses

SituationHelper
Show Bangla digits in a sentencetoBanglaDigits()
Convert Bangla digits back to EnglishtoEnglishDigits()
Keep month names or words unchangedUse digit helpers instead of full date formatting

Example

import { toBanglaDigits, toEnglishDigits } from "@coreify/tarikh";

toBanglaDigits("31 March 2026");
// -> "৩১ March ২০২৬"

toEnglishDigits("৩১ মার্চ ২০২৬");
// -> "31 March 2026"

Good Fit

This is useful for names, labels, counters, and mixed-language text where only the digits need to change.

On this page