anymany

Smart list formatter — sort and join arrays of strings in any Intl locale, one function.


Keywords
list, list-format, listformat, intl, i18n, localization, collator, sort, join, conjunction, disjunction, humanize, human-readable, formatter, lightweight, zero-dependency, typescript, esm, ssr, react
License
MIT
Install
npm install anymany@2.0.1

Documentation

anyfamily

website CI MIT

Home of the any* family — micro, zero-dependency JavaScript tools built on native Intl. The landing is one scroll-snapped page: a hero, then a full-screen section per package with a live, self-typing example. Every package also has an interactive demo at /<package> and an API reference at /docs/<package>, all served from this one app — the standalone per-package demo sites have been folded in.

anyfamily.site

the family

Package Does Intl API Links
anyaround region / language / script / currency / calendar names + flags Intl.DisplayNames demo · docs · npm · source
anyamount numbers, currency, units Intl.NumberFormat demo · docs · npm · source
anywhen dates, times, relative phrasing Intl.DateTimeFormat demo · docs · npm · source
anymany string lists Intl.ListFormat demo · docs · npm · source
anylong durations Intl.DurationFormat demo · docs · npm · source
anyplural cardinal / ordinal plurals Intl.PluralRules demo · docs · npm · source
anyword words / graphemes / sentences, count + truncate Intl.Segmenter demo · docs · npm · source
anylocale how a locale behaves: direction, week, calendars, time zones Intl.Locale info demo · docs · npm · source

how it works

  • Honest examples. Each demo imports the real package — workspace-linked to the source in packages/, so what you see is what the next release ships — and runs it in the browser. The revealed output is the genuine return value, never hardcoded. Presets are ordered simplest-first so the essence reads before the option-rich variants.
  • Live version badges. scripts/versions.mjs (a prebuild / predev step) pulls each package's latest version from the npm registry into data/versions.json, so every deploy shows current versions. It falls back to the installed version, then the committed file, so a build never fails on it.
  • SSR-safe. Outputs are computed only after mount, so the server render and first client render can't mismatch on ICU differences between Node and the browser.
  • SEO. Metadata, OpenGraph + Twitter cards, a generated OG image and favicon, robots.txt, sitemap.xml, JSON-LD (WebSite + an ItemList of SoftwareApplications with live versions), and a per-section <h2>.

dev

This is a pnpm workspace: the landing app at the root, and all ten packages under packages/.

pnpm install

# the site
pnpm dev          # refreshes versions, then next dev
pnpm build        # refreshes versions, then next build
pnpm lint

# the packages
pnpm --filter "./packages/*" test
pnpm --filter "./packages/*" build
pnpm --filter anywhen test        # just one

The site resolves the packages through their dist/, so rebuild a package after editing it or the demos keep showing the old output.

Releases go through changesets, by hand — the whole sequence is the start-to-finish checklist in RELEASING.md. Package layout and conventions are in PACKAGE-STANDARD.md.

Next.js 16 · React 19 · Tailwind v4 · TypeScript.

license

MIT © kirilinsky