Im building simple angular application. and i get error on component(book-add) html.
<div class="form-group">
<label for="title"><span class="req">* </span> Title:</label>
<input required type="text" [(ngModel)]="book.title" name="title" id="title"
class="form-control phone" maxlength="28" placeholder="Enter book title..." />
</div>
Property 'title' does not exist on type 'Book'.
in book-add.component.ts i intialized Book class and by default it is showing i can enter title and author so that means it recognized Book class
book: Book=new Book("","");
this is class book.ts
export class Book{
constructor(
title:String,
author:String
){}
}
Why i am getting this error