@saberhq/token-utils
Advanced tools
Comparing version 1.13.18 to 1.13.19
import { u64 } from "@solana/spl-token"; | ||
import type { BigintIsh, NumberFormat } from "@ubeswap/token-math"; | ||
import type { BigintIsh } from "@ubeswap/token-math"; | ||
import { TokenAmount as UTokenAmount } from "@ubeswap/token-math"; | ||
@@ -23,7 +23,2 @@ import type { Token } from "./token"; | ||
/** | ||
* Formats the token amount with units and decimal adjustment, e.g. "100.42 SOL" | ||
* @returns | ||
*/ | ||
formatUnits(format?: NumberFormat): string; | ||
/** | ||
* String representation of this token amount. | ||
@@ -30,0 +25,0 @@ */ |
@@ -36,9 +36,2 @@ "use strict"; | ||
/** | ||
* Formats the token amount with units and decimal adjustment, e.g. "100.42 SOL" | ||
* @returns | ||
*/ | ||
formatUnits(format = { groupSeparator: "," }) { | ||
return `${this.toExact(format)} ${this.token.symbol}`; | ||
} | ||
/** | ||
* String representation of this token amount. | ||
@@ -45,0 +38,0 @@ */ |
import { u64 } from "@solana/spl-token"; | ||
import type { BigintIsh, NumberFormat } from "@ubeswap/token-math"; | ||
import type { BigintIsh } from "@ubeswap/token-math"; | ||
import { TokenAmount as UTokenAmount } from "@ubeswap/token-math"; | ||
@@ -23,7 +23,2 @@ import type { Token } from "./token"; | ||
/** | ||
* Formats the token amount with units and decimal adjustment, e.g. "100.42 SOL" | ||
* @returns | ||
*/ | ||
formatUnits(format?: NumberFormat): string; | ||
/** | ||
* String representation of this token amount. | ||
@@ -30,0 +25,0 @@ */ |
@@ -32,9 +32,2 @@ import { u64 } from "@solana/spl-token"; | ||
/** | ||
* Formats the token amount with units and decimal adjustment, e.g. "100.42 SOL" | ||
* @returns | ||
*/ | ||
formatUnits(format = { groupSeparator: "," }) { | ||
return `${this.toExact(format)} ${this.token.symbol}`; | ||
} | ||
/** | ||
* String representation of this token amount. | ||
@@ -41,0 +34,0 @@ */ |
{ | ||
"name": "@saberhq/token-utils", | ||
"description": "Token-related math and transaction utilities for Solana.", | ||
"version": "1.13.18", | ||
"version": "1.13.19", | ||
"homepage": "https://github.com/saber-hq/saber-common/packages/token-utils#readme", | ||
@@ -27,6 +27,6 @@ "repository": "git+https://github.com/saber-hq/saber-common.git", | ||
"dependencies": { | ||
"@saberhq/solana-contrib": "^1.13.18", | ||
"@saberhq/solana-contrib": "^1.13.19", | ||
"@solana/buffer-layout": "^4.0.0", | ||
"@solana/spl-token": "^0.1.8", | ||
"@ubeswap/token-math": "^5.0.2", | ||
"@ubeswap/token-math": "^5.1.0", | ||
"tiny-invariant": "^1.2.0", | ||
@@ -42,3 +42,3 @@ "tslib": "^2.4.0" | ||
"devDependencies": { | ||
"@saberhq/tsconfig": "^1.13.18", | ||
"@saberhq/tsconfig": "^1.13.19", | ||
"@solana/web3.js": "^1.43.2", | ||
@@ -45,0 +45,0 @@ "@types/bn.js": "^5.1.0", |
import { u64 } from "@solana/spl-token"; | ||
import type { BigintIsh, NumberFormat } from "@ubeswap/token-math"; | ||
import type { BigintIsh } from "@ubeswap/token-math"; | ||
import { | ||
@@ -50,10 +50,2 @@ parseAmountFromString, | ||
/** | ||
* Formats the token amount with units and decimal adjustment, e.g. "100.42 SOL" | ||
* @returns | ||
*/ | ||
formatUnits(format: NumberFormat = { groupSeparator: "," }): string { | ||
return `${this.toExact(format)} ${this.token.symbol}`; | ||
} | ||
/** | ||
* String representation of this token amount. | ||
@@ -60,0 +52,0 @@ */ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
376668
5481