let users = [{ firstName: "Ahmed", lastName: "ElNawawy", }, { firstName: "Khaled", lastName: "ElNawawy", } ]; users.sort((a, b) => a.firstname.localeCompare(b.firstname))