<p>Hello {{user.firstname}}</p>
<div>
    <table>
        @for(book of allBooks; track book.name){
            <tr>
                <td>
                    <input type='radio' name='selectBook' [(ngModel)]="selectedBookName" value={{book.name}}>
                    
                    {{book.name}}
                </td>
                <td>{{book.author}}</td>
                <td>{{book.pages}}</td>
                <td>{{book.likes}}</td>
                <td>{{book.date | date: 'short'}}</td>
                <td>
                    <input type="checkbox" [(ngModel)]="book.toLike">
                </td>
            </tr>
        }
    </table>
    <select multiple size="2" [(ngModel)]="allSelected">
        @for(book of allBooks; track book.name){
            <option>{{book.name}}</option>
        }
    </select>
    <button (click)="likeAll()">Like all</button>
    <button (click)="getSelected()">Selected</button>
</div>
