Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
D

date-and-time

> 数据库
Open source

The simplest, most intuitive date and time library

188 stars0 likes3 views
WebsiteGitHub

About

The simplest, most intuitive date and time library

date-and-time

The simplest, most intuitive date and time library.

Installation

bash
npm install date-and-time

ES Modules (Recommended)

typescript
import { format } from 'date-and-time';

format(new Date(), 'ddd, MMM DD YYYY');
// => Wed, Jul 09 2025

CommonJS

typescript
const { format } = require('date-and-time');

format(new Date(), 'ddd, MMM DD YYYY');
// => Wed, Jul 09 2025

CDN Usage

Via jsDelivr

xml

Via unpkg

xml

Migration

Version 4.x has been completely rewritten in TypeScript and some features from 3.x are no longer compatible. The main changes are as follows:

  • The timezone and timespan plugins have been integrated into the main library
  • Tree shaking is now supported
  • Supports ES2021 and no longer supports older browsers

For details, please refer to migration.md.

API

For comprehensive documentation and examples, visit: GitHub Pages

License

MIT

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

TypeScriptdatedurationformatjavascript

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 18, 2026
Category数据库
PricingOpen source

> Related tools

P
PostgreSQL
功能强大的开源关系型数据库
R
Redis
内存数据结构存储,常用作缓存与队列
M
MySQL
广泛使用的开源关系型数据库