Angular date & time picker

GitHub license npm scope

Simple responsive Angular date and time picker.

Quick links

Installing

Example :
npm install --save nxt-pick-datetime
npm install --save moment   # if you want to use MomentDateTimeModule

Configure DateTime adapter provider

The date & time picker was built to be date implementation agnostic. It comes with two date adapter implementations, or you can provide your own adapter by implementing DateTimeAdapter (see documentation).

  • provideNativeDateTimeAdapter - support for native JavaScript Date object
  • provideNativeDateTimeAdapter - support for MomentJs
Example :
import { ApplicationConfig } from '@angular/core'
import { provideNativeDateTimeAdapter } from 'nxt-pick-datetime/native-adapter'

export const appConfig: ApplicationConfig = {
    providers: [
        provideNativeDateTimeAdapter()
    ]
}

Use it in a template

Example :
<input [nxtDateTime]="picker"
    [nxtDateTimeTrigger]="picker"
    placeholder="Date and time">
<nxt-date-time #picker></nxt-date-time>

results matching ""

    No results matching ""