Trying to sort in descending/ascending/default and there are some type error, unable to solve the issue when accessing like sortTypes[currentSort].fn and how can i resolve t