function sort(type) {
$("#parentDiv").empty();
$.getJSON("raw_data.json", ({ Search }) => {
Search.sort((a, b) => a[type] > b[type]);
console.log(`Sorted by: ${type}`);
...code
Different results are shown in different browsers, but the correct one is showing in firefox devoloper edition and wrong results are shown in chrome browser.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…