I'm trying to set up default value for my selection so I tried
[selected]= "selected_choice == 'one'"
something like this
but this didn't work.
People said [selected] no longer works so I also tried [attr.selected] but didn't work as well..
this is my whole code for one select tag
<select (change)="passValue3()" formControlName="school" class="form-control" required [(ngModel)]="selected_student" class="selectionbox">
<option *ngIf="selected_student == undefined">학년 선택</option>
<option *ngFor="let gradetype of gradeTypes" [ngValue]="gradetype" [attr.selected] = "gradetype.gradeType === 'Middle'">{{gradetype.gradeName}}</option>
</select>
How can I set up the default option for the select?