From 7d0e96c6cd30245788b66d250a43e76316746bdf Mon Sep 17 00:00:00 2001 From: Ivan Kalinin Date: Wed, 16 Oct 2024 17:06:51 +0200 Subject: [PATCH] Sort abi by name --- src/components/ExecutorAbiForm.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/ExecutorAbiForm.vue b/src/components/ExecutorAbiForm.vue index 77a9748..eaf1bd5 100644 --- a/src/components/ExecutorAbiForm.vue +++ b/src/components/ExecutorAbiForm.vue @@ -11,8 +11,9 @@ enum LoadAbiType { } const DEFAULT_ABI_NAME = 'abi1'; +const COLLATOR = new Intl.Collator(undefined, { numeric: true, sensitivity: 'base' }); -const getAllAbis = () => Object.keys(localStorage); +const getAllAbis = () => Object.keys(localStorage).sort(COLLATOR.compare); const props = defineProps<{ address?: string;