From c081963dace3aeaa494b16c07290e8dd05b5ae07 Mon Sep 17 00:00:00 2001 From: abefernan <44572727+abefernan@users.noreply.github.com> Date: Thu, 27 Apr 2023 16:31:36 +0200 Subject: [PATCH] Add capitalizeFirstLetter helper --- lib/displayHelpers.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/displayHelpers.ts b/lib/displayHelpers.ts index 4e8a12f..f238d40 100644 --- a/lib/displayHelpers.ts +++ b/lib/displayHelpers.ts @@ -4,6 +4,10 @@ import { fromBase64, fromBech32, toBase64, toBech32 } from "@cosmjs/encoding"; import { Decimal } from "@cosmjs/math"; import { ChainInfo } from "../types"; +function capitalizeFirstLetter(str: string): string { + return str.charAt(0).toUpperCase() + str.slice(1); +} + function ellideMiddle(str: string, maxOutLen: number): string { if (str.length <= maxOutLen) { return str;