npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

datetick

v1.2.0

Published

DateTick — a tiny, immutable, fully timezone-aware date toolkit: formatting, parsing, durations and live relative-time, for any framework.

Readme

TypeScript GitHub contributors GitHub License GitHub Actions Workflow Status GitHub package.json version Known Vulnerabilities Bundle Size

ESLint Prettier Jest Maintenance codecov Socket Badge

NPM Downloads


DateTick parses, validates, manipulates, formats and compares dates and times — with every calendar operation resolved through a real IANA timezone, so one absolute instant is always interpreted consistently in one zone (DST included). Zero runtime dependencies. Works the same in vanilla JS, Angular, React, Vue and Node.

import datetick from 'datetick';

datetick('2026-06-25T19:23Z', { timezone: 'Asia/Tokyo' }).formatPattern('DD/MM/YYYY HH:mm'); // '26/06/2026 04:23'

datetick('2026-06-25').startOf('month').add(1, 'day').set('year', 2027).format('long');

datetick.duration(90, 'minute').humanize(); // '2 hours'
datetick('2026-06-25').timeAgoLive().subscribe(console.log); // live "time ago" stream
  • 🌐 Fully timezone-aware — reading components, add/subtract, startOf/endOf, weeks and formatting all resolve through the configured IANA timezone
  • 💪 Immutable & chainable — every method returns a new instance; safe to share across Angular components, React renders and Vue computeds
  • 📦 Zero runtime dependencies — locales come from the platform's Intl, so there are no locale files to import
  • 🕒 Familiar API — Day.js-style tokens, getters/setters, comparisons and relative time
  • Durations & live "time ago" — ISO 8601 durations, humanize(), and a dependency-free live relative-time stream
  • 🗓️ Calendar-grid data — ready-to-render month grids for building date pickers
  • 🔒 TypeScript-first — full types shipped, ESM + UMD builds

Getting Started

Installation

npm install datetick

Live demo & documentation

The full API reference — getters/setters, manipulation, comparisons, formatting/parsing tokens, durations, calendar-grid data, app-wide locale defaults, and copy-paste Angular / React / Vue integration (including a runtime language switcher) — plus a live in-browser playground, is hosted on GitHub Pages:

➡️ andreasnicolaou.github.io/datetick

You can also open docs/index.html directly in a browser — no build step required.

API

It's easy to use DateTick to parse, validate, manipulate and display dates and times.

datetick('2026-08-08'); // parse

datetick().format('YYYY-MM-DD HH:mm:ss'); // display (token pattern)
datetick().format('long'); // display (Intl preset)

datetick().set('month', 3).month(); // get & set

datetick().add(1, 'year').subtract(3, 'day'); // manipulate

datetick().isBefore(datetick()); // query
datetick('2026-06-25').isBetween('2026-06-01', '2026-07-01', '[)');

Timezones

Every operation is resolved through the configured timezone, so the same instant is interpreted consistently — across DST transitions too.

const t = datetick('2026-06-25T19:23Z', { timezone: 'Asia/Tokyo' });
t.hour(); // 4  (wall-clock hour in Tokyo)
t.utc().hour(); // 19 (same instant, UTC)
t.utcOffset(); // 540

Locale-aware, without locale files

Locales resolve through the platform's Intl, so nothing extra needs to be imported.

datetick('2026-06-25', { locale: 'fr' }).format('long'); // French
datetick('2026-06-25', { locale: 'fr' }).localeData().months()[0]; // 'janvier'

App-wide defaults

Bind locale / timezone / week start once and reuse the scoped factory — no global mutation.

const paris = datetick.withDefaults({ locale: 'fr', timezone: 'Europe/Paris' });
paris('2026-06-25').format('long'); // French, Paris
datetick('2026-06-25').format('long'); // unaffected

License

DateTick is licensed under the MIT License © Andreas Nicolaou.