{"action":"created","issue":{"url":"https://api.github.com/repos/quran/quran.com-frontend/issues/57","repository_url":"https://api.github.com/repos/quran/quran.com-frontend","labels_url":"https://api.github.com/repos/quran/quran.com-frontend/issues/57/labels{/name}","comments_url":"https://api.github.com/repos/quran/quran.com-frontend/issues/57/comments","events_url":"https://api.github.com/repos/quran/quran.com-frontend/issues/57/events","html_url":"https://github.com/quran/quran.com-frontend/issues/57","id":98212726,"number":57,"title":"Organize languages in dropdown by alphabet order","user":{"login":"mmahalwy","id":3749095,"avatar_url":"https://avatars.githubusercontent.com/u/3749095?v=3","gravatar_id":"","url":"https://api.github.com/users/mmahalwy","html_url":"https://github.com/mmahalwy","followers_url":"https://api.github.com/users/mmahalwy/followers","following_url":"https://api.github.com/users/mmahalwy/following{/other_user}","gists_url":"https://api.github.com/users/mmahalwy/gists{/gist_id}","starred_url":"https://api.github.com/users/mmahalwy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmahalwy/subscriptions","organizations_url":"https://api.github.com/users/mmahalwy/orgs","repos_url":"https://api.github.com/users/mmahalwy/repos","events_url":"https://api.github.com/users/mmahalwy/events{/privacy}","received_events_url":"https://api.github.com/users/mmahalwy/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/quran/quran.com-frontend/labels/Great%20for%20starters","name":"Great for starters","color":"1d76db"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2015-07-30T16:37:56Z","updated_at":"2016-08-25T00:31:04Z","closed_at":null,"body":""},"comment":{"url":"https://api.github.com/repos/quran/quran.com-frontend/issues/comments/242249221","html_url":"https://github.com/quran/quran.com-frontend/issues/57#issuecomment-242249221","issue_url":"https://api.github.com/repos/quran/quran.com-frontend/issues/57","id":242249221,"user":{"login":"sabeurthabti","id":2606228,"avatar_url":"https://avatars.githubusercontent.com/u/2606228?v=3","gravatar_id":"","url":"https://api.github.com/users/sabeurthabti","html_url":"https://github.com/sabeurthabti","followers_url":"https://api.github.com/users/sabeurthabti/followers","following_url":"https://api.github.com/users/sabeurthabti/following{/other_user}","gists_url":"https://api.github.com/users/sabeurthabti/gists{/gist_id}","starred_url":"https://api.github.com/users/sabeurthabti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sabeurthabti/subscriptions","organizations_url":"https://api.github.com/users/sabeurthabti/orgs","repos_url":"https://api.github.com/users/sabeurthabti/repos","events_url":"https://api.github.com/users/sabeurthabti/events{/privacy}","received_events_url":"https://api.github.com/users/sabeurthabti/received_events","type":"User","site_admin":false},"created_at":"2016-08-25T00:31:03Z","updated_at":"2016-08-25T00:31:03Z","body":"Example of sorting alphabetically on objects within an array:\r\n\r\n`export function alphabetically(property) {\r\n\r\n  return (a, b) => {\r\n    const textA = a[property].toUpperCase();\r\n    const textB = b[property].toUpperCase();\r\n\r\n    if (textA < textB) {\r\n      return -1;\r\n    }\r\n\r\n    if (textA > textB) {\r\n      return 1;\r\n    }\r\n\r\n    return 0;\r\n  };\r\n}`\r\n\r\nusage:\r\n\r\n`[{name: \"English\"}, {name: \"Arabic\"}].sort(alphabetically('name')`\r\n"}}
{"actor":{"display_login":"sabeurthabti"}}