change sorting function name
This commit is contained in:
parent
0182d6118f
commit
0a28cf16e3
1 changed files with 5 additions and 2 deletions
|
@ -65,7 +65,10 @@ const styles = StyleSheet.create({
|
|||
},
|
||||
});
|
||||
|
||||
function sortFinalData(a: ProximoCategoryType, b: ProximoCategoryType): number {
|
||||
function sortCategories(
|
||||
a: ProximoCategoryType,
|
||||
b: ProximoCategoryType
|
||||
): number {
|
||||
const str1 = a.name.toLowerCase();
|
||||
const str2 = b.name.toLowerCase();
|
||||
|
||||
|
@ -217,7 +220,7 @@ function ProximoMainScreen() {
|
|||
return [
|
||||
{
|
||||
title: '',
|
||||
data: finalData.filter((c) => c.nb_articles > 0).sort(sortFinalData),
|
||||
data: finalData.filter((c) => c.nb_articles > 0).sort(sortCategories),
|
||||
keyExtractor: getKeyExtractor,
|
||||
},
|
||||
];
|
||||
|
|
Loading…
Reference in a new issue