I have a object as follow:
this.student = {};
this.student.id = '';
this.student.name = '';
this.student.class = '';
this.student.percentage = '';
How do i check if my student object is empty or not?
I have a object as follow:
this.student = {};
this.student.id = '';
this.student.name = '';
this.student.class = '';
this.student.percentage = '';
How do i check if my student object is empty or not?
To Check bject for empty try this
Object.keys(this.student).length === 0