I have the same problem, I tried:
dataSource = computed(() => new MatTableDataSource(this.data()))
In my html file I have this:
table mat-table [dataSource]="dataSource()"...
It works for the data but not for the Sort...
So I tried:
ngAfterViewInit(): void { this.dataSource().sort = this.sort; }
But that does not work either...