I'm using Angular version 20. Month and year selection are missing. I have tried more methods, however I am still facing issues.
Imports:
CommonModule, FormsModule, ReactiveFormsModule, NgScrollbarModule, CardComponent, MaterialModules,NgbDatepickerModule, NgbModule
(https://i.sstatic.net/7oZaPyBe.png)
<div class="row p-t-25">
<div class="col-12">
<app-card cardTitle="Hello card">
<form #userlogin="ngForm">
<div class="row">
<div class="col">
<div class="form-group">
<label class="float-label"><span class="red">*</span>From Date</label>
<div class="input-group py-2">
<input
class="form-control"
placeholder="yyyy-mm-dd"
name="fromDate"
[(ngModel)]="formData.fromDate"
ngbDatepicker
#d2="ngbDatepicker"
[navigation]="'select'"
/>
<button class="btn btn-outline-secondary bi bi-calendar3" type="button" (click)="d2.toggle()">
📅
</button>
</div>
</div>
</div>
<div class="col">
<div class="form-group">
<label class="float-label"><span class="red">*</span>To Date</label>
<div class="input-group py-2">
<input
class="form-control"
placeholder="yyyy-mm-dd"
name="dp"
[(ngModel)]="formData.toDate"
ngbDatepicker
#d="ngbDatepicker"
/>
<button class="btn btn-outline-secondary bi bi-calendar3" (click)="d.toggle()" type="button"> 📅</button>
</div>
</div>
</div>
</div>
<hr class="mt-4" style="color: darkgrey;">
</form>
</app-card>
</div>
</div>