Registry-first Bikram Sambat (BS) date pickers for React (web) and React Native (Expo). Copy components into your app with the shadcn CLI — no npm runtime dependency.
The headless calendar engine lives in lib/bs-day-picker/ (BsDayPicker, useBsCalendar). Registry items are bs-calendar and bs-date-picker.
git clone https://github.com/binodnepali/react-nepali-datetime-picker.git
cd react-nepali-datetime-picker
pnpm install
pnpm registry:build
pnpm devDocs: Getting started
After hosting docs (GitHub Pages: https://binodnepali.github.io/react-nepali-datetime-picker/), use apps/docs/public/r/ (web) or r-native/ (Expo):
{
"registries": {
"@react-nepali-datetime-picker": "https://binodnepali.github.io/react-nepali-datetime-picker/r/{name}.json"
}
}pnpm dlx shadcn@latest add @react-nepali-datetime-picker/bs-calendar
pnpm dlx shadcn@latest add @react-nepali-datetime-picker/bs-date-pickerExpo / React Native: use @react-nepali-datetime-picker-native → r-native/{name}.json. See React Native guide.
| Path | Purpose |
|---|---|
packages/core |
@react-nepali-datetime-picker/core — BS calendar data + headless hook |
registry/web, registry/native |
shadcn registry sources |
apps/docs |
VitePress site + hosted registry JSON |
scripts/scrape-hamropatro.mjs |
Regenerate bs-calendar.json from Hamro Patro |
| Command | Description |
|---|---|
pnpm dev |
Docs dev server |
pnpm registry:build |
Build web + native registry JSON |
pnpm data:scrape |
Refresh Hamro Patro cache (use -- --years 2080-2089) |
pnpm data:build |
Merge cache into full bs-calendar.json |
pnpm data:refresh |
Scrape + build + validate (chain) |
pnpm test |
Vitest (packages/core) |
pnpm release:check |
Test, types, registry build + verify committed JSON |
Versioning: VERSIONING.md (release-please Release PRs)
MIT