var objs = [ {'name': 'A', 'type': 'fly'}, {'name': 'B', 'type': 'blur'}, {'name': 'C', 'type': 'wipe'}, {'name': 'D', 'type': 'cube'}, {'name': 'E', 'type': 'iris'}, {'name': 'F', 'type': 'fade'} ]; objs.sort(function(a,b){ return a.type.localeCompare(b.type,"zh") }); console.log(objs);//
0: {name: "B", type: "blur"} 1: {name: "D", type: "cube"} 2: {name: "F", type: "fade"} 3: {name: "A", type: "fly"} 4: {name: "E", type: "iris"} 5: {name: "C", type: "wipe"}