Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@saberhq/token-utils

Package Overview
Dependencies
Maintainers
2
Versions
209
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@saberhq/token-utils - npm Package Compare versions

Comparing version 1.13.18 to 1.13.19

7

dist/cjs/tokenAmount.d.ts
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 @@ */

8

package.json
{
"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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc