Properly sort item lists alphabetically
This commit is contained in:
parent
8a44d520db
commit
2f15db7d4e
1 changed files with 5 additions and 1 deletions
|
@ -177,7 +177,11 @@ export class BladesHelpers {
|
|||
compendium_items = compendium_content.map(e => {return e.data});
|
||||
|
||||
list_of_items = game_items.concat(compendium_items);
|
||||
|
||||
list_of_items.sort(function(a, b) {
|
||||
let nameA = a.name.toUpperCase();
|
||||
let nameB = b.name.toUpperCase();
|
||||
return nameA.localeCompare(nameB);
|
||||
});
|
||||
return list_of_items;
|
||||
|
||||
}
|
||||
|
|
Reference in a new issue