We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
formatNearAmount
1 parent 9424189 commit 18a696bCopy full SHA for 18a696b
.changeset/nice-nails-remain.md
@@ -0,0 +1,6 @@
1
+---
2
+"@near-js/utils": patch
3
+"near-api-js": patch
4
5
+
6
+Extend input type for `formatNearAmount` function
packages/utils/src/format.ts
@@ -30,7 +30,7 @@ for (
30
* @returns Value in Ⓝ
31
*/
32
export function formatNearAmount(
33
- balance: string,
+ balance: string | number | bigint,
34
fracDigits: number = NEAR_NOMINATION_EXP
35
): string {
36
let balanceBN = BigInt(balance);
0 commit comments