Angular Datetime Package
ngx-datetime
Time-focused Angular helpers for formatting, ranges, arithmetic, and calendar logic.
A focused extraction of the Datetime feature from ngx-core, documented as its own package with dark/light theming and translations.
landing.ts
Project Overview
Package
ngx-datetime
A single-purpose Angular package for date formatting, period boundaries, date arithmetic, and calendar helpers.
License
MIT
Published as a public package and designed for reuse across multiple apps.
Installation
Install the package
$ npm i --save ngx-datetimeUsage
Bootstrap with provideNgxDatetime()
import { provideNgxDatetime } from 'ngx-datetime';
export const appConfig = {
providers: [provideNgxDatetime()],
};Configuration
Pair metadata with datetime helpers
Use provideNgxCore() for app metadata and add provideNgxDatetime() for the focused datetime feature.
import { provideNgxCore } from 'ngx-core';
import { provideNgxDatetime } from 'ngx-datetime';
export const appConfig = {
providers: [
provideNgxCore({
meta: {
applyFromRoutes: true,
defaults: { links: {} },
},
}),
provideNgxDatetime(),
],
};Features
What ngx-datetime includes
Bootstrap
Focused setup centered on provideNgxDatetime() with optional ngx-core metadata defaults.
provideNgxDatetime() | DatePipe dependency registration | Works alongside provideNgxCore()
Datetime service
One focused injectable for common date naming, formatting, arithmetic, and range helpers.
TimeService | Formatting, timezone conversion, and locale-aware week boundaries | Day / week / month / year helpers plus date math
Reference
Documented feature pages
The detailed page below covers the public API surface for the extracted datetime package.
