Tsena Kely
Antananarivo
Faktiora
Laharana 2026-0042
dimy alina sy iray hetsy ariary
Spell numbers, read +261 phone numbers, format Ariary amounts and dates. For JavaScript, TypeScript and PHP, with zero dependencies and the same result everywhere.
import { formatAriary, spellAriary } from '@mdgascar/ariary';import { formatPhone } from '@mdgascar/phone-number';import { formatDate } from '@mdgascar/date-time'; const receipt = { amount: formatAriary(150000), words: spellAriary(150000), phone: formatPhone('0341234567', 'international'), date: formatDate('2026-11-23', 'full'),} satisfies Record<string, string>;use Mdgascar\MalagasyIntl\Ariary\Ariary;use Mdgascar\MalagasyIntl\PhoneNumber\{PhoneNumber, PhoneNumberFormat};use Mdgascar\MalagasyIntl\DateTime\{DateStyle, MalagasyDate}; $receipt = [ 'amount' => Ariary::fromInt(150000)->format(), 'words' => Ariary::fromInt(150000)->spell(), 'phone' => PhoneNumber::parse('0341234567')->format(PhoneNumberFormat::International), 'date' => MalagasyDate::fromString('2026-11-23')->format(DateStyle::Full),];Tsena Kely
Antananarivo
Faktiora
Laharana 2026-0042
dimy alina sy iray hetsy ariary
Any JavaScript or TypeScript project, on the server or in the browser. Types are built in, so the editor knows every option and error code.
Requirements Node.js 22.18+, Bun, Deno and modern browsers · ESM and CommonJS · TypeScript types included · zero dependencies
npm i @mdgascar/malagasy-intlpnpm add @mdgascar/malagasy-intlbun add @mdgascar/malagasy-intlnpmOne package per module, or all of themExamples for every framework
Any PHP 8.3+ project: plain PHP, WordPress or any framework through Composer, with ready-made packages for Laravel and Symfony.
Requirements PHP 8.3, 8.4, 8.5 · Laravel 12 and 13 · Symfony 7.4 LTS and 8 · zero dependencies
composer require mdgascar/malagasy-intlcomposer require mdgascar/malagasy-intl-laravelcomposer require mdgascar/malagasy-intl-symfonyComposerLaravel: Validation rules, Eloquent casts, Blade directivesSymfony: Constraints, Twig filters, Doctrine typesExamples for every framework