-
Notifications
You must be signed in to change notification settings - Fork 0
Contributing
github-actions[bot] edited this page May 29, 2026
·
1 revision
- Node.js 20 or later
- pnpm (enabled via corepack:
corepack enable)
git clone https://github.com/acamarata/hijri-core.git
cd hijri-core
pnpm installpnpm build # compile TypeScript
pnpm test # build + run test suite
pnpm run typecheck # type-check without emitting
pnpm run lint # ESLint
pnpm run format # Prettier formatThe package ships two engines:
- UAQ (Umm al-Qura): table-based, identical to the official Saudi calendar
- FCNA: an algorithmic engine for Fiqh Council of North America calculations
When modifying either engine, cross-validate against the reference tables in the test suite. The UAQ table covers 1318-1500 AH; the FCNA engine is unbounded but less authoritative outside that range.
hijri-core is the foundation for several thin wrapper packages:
-
luxon-hijri,date-fns-hijri,dayjs-hijri-plus,moment-hijri-plus,temporal-hijri(JS) -
hijri_core(Dart)
Breaking changes here require coordinated updates across all downstream packages. When changing the public API, note which downstream packages are affected in your PR description.
- One logical change per PR
- Include tests with cross-validation against known dates
- Update
CHANGELOG.mdunder[Unreleased] - Do not bump the version number
Reference
API
- toHijri
- toGregorian
- isValidHijriDate
- daysInHijriMonth
- registerCalendar
- getCalendar
- listCalendars
- hDatesTable
- hmLong / hmMedium / hmShort
- hwLong / hwShort / hwNumeric
Guides
Examples
Contributing
Links