nxt-pick-datetime
v18.0.0
Published
Date time picker for Angular
Downloads
203
Maintainers
Readme
Angular date & time picker
Simple responsive Angular date and time picker.
Quick links
Installing
npm install --save nxt-pick-datetime
npm install --save moment # if you want to use MomentDateTimeModule
Import main module and DateTime adapter provider
The date & time picker was built to be date implementation agnostic. It comes with two modules providing date adapter implementation, or you can provide your own adapter by implementing DateTimeAdapter
(see documentation).
NativeDateTimeModule
- support for native JavaScript Date objectMomentDateTimeModule
- support for MomentJs
import { DateTimeModule } from 'nxt-pick-datetime'
import { NativeDateTimeModule } from 'nxt-pick-datetime/native-adapter'
@NgModule({
...
imports: [
...
DateTimeModule,
NativeDateTimeModule
]
})
Use it in a template
<input [nxtDateTime]="picker"
[nxtDateTimeTrigger]="picker"
placeholder="Date and time">
<nxt-date-time #picker></nxt-date-time>