var arr = [
{name:'a'},
{name:'f'},
{name:'e'},
{name:'c'},
{name:'b'},
]
arr.sort(function(a,b){
return a.name.localeCompare(b.name)
})
console.log(arr)
var arr = [
{name:'a'},
{name:'f'},
{name:'e'},
{name:'c'},
{name:'b'},
]
arr.sort(function(a,b){
return a.name.localeCompare(b.name)
})
console.log(arr)