I have a normal Angular Material 2 DataTable with sort headers. All sort are headers work fine. Except for the one with an object as value. These doesn\'t sort at all.
I had the same issue, by testing the first proposition I had some errors, I could fixe it by adding "switch (property)"
this.dataSource.sortingDataAccessor =(item, property) => { switch (property) { case 'project.name': return item.project.name; default: return item[property]; } };