Typescript Object Array sorting
Demonstrate the approach of sorting object array in typescript.
var students = [
{ 'id': 1, 'name': 'Kelvin'},
{ 'id': 1, 'name': 'Marry'},
{ 'id': 1, 'name': 'John'},
]
Object array sort with comparison logic
//ascending order
sortedStudents