I am trying to fetch all the date from this database so the user can only select those dates (without HHMMSS, just the YYYYMMDD) available in the db from the datetimepicker. The reason i need this because i will use the datetimepicker as a page filter showing only datas for the selected date.
<ion-item *ngFor="let item of fogasadatok; let i = index">
<ion-label>Start Time</ion-label>
<ion-datetime displayFormat="YYYY-MM-DD" pickerFormat="YYYY-MM-DD" [(ngModel)]="event.timeStarts"></ion-datetime>
</ion-item>
I have no idea how to continue this code, can you show me the way?
@saimon Just FYI: the conventional wisdom on the board right now is that date-fns is better for Ionic apps than momentJS. I agree with this - more lightweight, better tree shaking. The only area Moment is better is in definition of complex and conditional time zones. This could change tomorrow with new updates etc., but for now, you might benefit from exploring date-fns.