Sort an array of notes in ascending order. Pitch classes are listed before notes. Any string that is not a note is removed.
sorted array of notes
sortedNoteNames(['c2', 'c5', 'c1', 'c0', 'c6', 'c'])// => ['C', 'C0', 'C1', 'C2', 'C5', 'C6']sortedNoteNames(['c', 'F', 'G', 'a', 'b', 'h', 'J'])// => ['C', 'F', 'G', 'A', 'B'] Copy
sortedNoteNames(['c2', 'c5', 'c1', 'c0', 'c6', 'c'])// => ['C', 'C0', 'C1', 'C2', 'C5', 'C6']sortedNoteNames(['c', 'F', 'G', 'a', 'b', 'h', 'J'])// => ['C', 'F', 'G', 'A', 'B']
Sort an array of notes in ascending order. Pitch classes are listed before notes. Any string that is not a note is removed.