Tarikh
Formatting

Standard Formatting

Show a normal Gregorian date with optional locale, weekday, time, and presets.

Start Here

Use standard formatting when you want a Gregorian date label with a small surface area.

Quick Rule

If you want a familiar article date, event card date, or dashboard timestamp, start here.

If you need the Bangla calendar itself, go to Bangla Formatting.

Common Choices

What you wantUse
A short English datemode: "standard"
A Bangla-localized date labelmode: "standard", locale: "bn-BD"
More date contextAdd weekday, hour, minute, or second
Faster common presetsAdd `preset: "date"

Example

import { format } from "@coreify/tarikh";

format("2026-03-31", { mode: "standard" });
// -> "31st Mar 2026"

format("2026-03-31", { mode: "standard", locale: "bn-BD" });
// -> "৩১শে মার্চ ২০২৬ খ্রিস্টাব্দ"

format(new Date(2026, 2, 31, 15, 4, 9), {
  mode: "standard",
  preset: "dateTime",
});
// -> "31st Mar 2026, 15:04"

format(new Date(2026, 2, 31, 15, 4, 9), {
  mode: "standard",
  preset: "isoLike",
});
// -> "2026-03-31 15:04:09"

Good Fit

This is the right choice for dashboards, articles, event cards, and anything that should still look like a regular date.

On this page