You're Invited:Meet the Socket Team at RSAC and BSidesSF 2026, March 23–26.RSVP
Socket
Book a DemoSign in
Socket

@solana/web3.js

Package Overview
Dependencies
Maintainers
2
Versions
1969
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@solana/web3.js - npm Package Compare versions

Comparing version
1.98.0
to
1.98.1
+5
-5
package.json
{
"name": "@solana/web3.js",
"version": "1.98.0",
"version": "1.98.1",
"description": "Solana Javascript API",

@@ -14,6 +14,6 @@ "keywords": [

"type": "git",
"url": "https://github.com/solana-labs/solana-web3.js.git"
"url": "https://github.com/solana-foundation/solana-web3.js.git"
},
"bugs": {
"url": "http://github.com/solana-labs/solana-web3.js.git/issues"
"url": "http://github.com/solana-foundation/solana-web3.js.git/issues"
},

@@ -48,3 +48,3 @@ "publishConfig": {

"prepublishOnly": "pnpm pkg delete devDependencies",
"publish-packages": "semantic-release --repository-url git@github.com:solana-labs/solana-web3.js.git",
"publish-packages": "semantic-release --repository-url git@github.com:solana-foundation/solana-web3.js.git",
"test:lint": "eslint src/ test/ --ext .js,.ts",

@@ -65,4 +65,4 @@ "test:lint:fix": "eslint src/ test/ --fix --ext .js,.ts",

"@solana/buffer-layout": "^4.0.1",
"@solana/codecs-numbers": "^2.1.0",
"agentkeepalive": "^4.5.0",
"bigint-buffer": "^1.1.5",
"bn.js": "^5.2.1",

@@ -69,0 +69,0 @@ "borsh": "^0.7.0",

@@ -16,3 +16,3 @@ [![npm][npm-image]][npm-url]

> [!NOTE]
> This is the maintenance branch for the 1.x line of `@solana/web3.js`. You can find the successor to this library [here](https://l.anza.xyz/s/js-sdk-repo).
> This is the maintenance branch for the 1.x line of `@solana/web3.js`. You can find the successor to this library here: [`@solana/kit`](https://l.anza.xyz/s/js-sdk-repo).

@@ -28,3 +28,3 @@ # Solana JavaScript SDK (v1.x)

```
$ npm install --save @solana/web3.js@1
$ npm install --save @solana/web3.js
```

@@ -45,3 +45,3 @@

- [The Solana Cookbook](https://solanacookbook.com/) has extensive task-based documentation using this library.
- For more detail on individual functions, see the [latest API Documentation](https://solana-labs.github.io/solana-web3.js)
- For more detail on individual functions, see the [latest API Documentation](https://solana-foundation.github.io/solana-web3.js)

@@ -107,3 +107,3 @@ ## Getting help

If you found a bug or would like to request a feature, please [file an issue](https://github.com/solana-labs/solana-web3.js/issues/new). If, based on the discussion on an issue you would like to offer a code change, please make a [pull request](https://github.com/solana-labs/solana-web3.js/compare). If neither of these describes what you would like to contribute, read the [getting help](#getting-help) section above.
If you found a bug or would like to request a feature, please [file an issue](https://github.com/solana-foundation/solana-web3.js/issues/new). If, based on the discussion on an issue you would like to offer a code change, please make a [pull request](https://github.com/solana-foundation/solana-web3.js/compare). If neither of these describes what you would like to contribute, read the [getting help](#getting-help) section above.

@@ -110,0 +110,0 @@ ## Disclaimer

@@ -1,3 +0,3 @@

import {toBufferLE} from 'bigint-buffer';
import * as BufferLayout from '@solana/buffer-layout';
import {getU64Encoder} from '@solana/codecs-numbers';

@@ -275,3 +275,6 @@ import * as Layout from '../../layout';

const [lookupTableAddress, bumpSeed] = PublicKey.findProgramAddressSync(
[params.authority.toBuffer(), toBufferLE(BigInt(params.recentSlot), 8)],
[
params.authority.toBuffer(),
getU64Encoder().encode(params.recentSlot) as Uint8Array,
],
this.programId,

@@ -278,0 +281,0 @@ );

import {Buffer} from 'buffer';
import {blob, Layout} from '@solana/buffer-layout';
import {toBigIntLE, toBufferLE} from 'bigint-buffer';
import {getU64Codec} from '@solana/codecs-numbers';
interface EncodeDecode<T> {
decode(buffer: Buffer, offset?: number): T;
encode(src: T, buffer: Buffer, offset?: number): number;
}
const encodeDecode = <T>(layout: Layout<T>): EncodeDecode<T> => {
export function u64(property?: string): Layout<bigint> {
const layout = blob(8 /* bytes */, property);
const decode = layout.decode.bind(layout);
const encode = layout.encode.bind(layout);
return {decode, encode};
};
const bigInt =
(length: number) =>
(property?: string): Layout<bigint> => {
const layout = blob(length, property);
const {encode, decode} = encodeDecode(layout);
const bigIntLayout = layout as Layout<unknown> as Layout<bigint>;
const codec = getU64Codec();
const bigIntLayout = layout as Layout<unknown> as Layout<bigint>;
bigIntLayout.decode = (buffer: Buffer, offset: number) => {
const src = decode(buffer as Uint8Array, offset);
return codec.decode(src);
};
bigIntLayout.decode = (buffer: Buffer, offset: number) => {
const src = decode(buffer, offset);
return toBigIntLE(Buffer.from(src));
};
bigIntLayout.encode = (bigInt: bigint, buffer: Buffer, offset: number) => {
const src = toBufferLE(bigInt, length);
return encode(src, buffer, offset);
};
return bigIntLayout;
bigIntLayout.encode = (bigInt: bigint, buffer: Buffer, offset: number) => {
const src = codec.encode(bigInt) as Uint8Array;
return encode(src, buffer as Uint8Array, offset);
};
export const u64 = bigInt(8);
export const u128 = bigInt(16);
export const u192 = bigInt(24);
export const u256 = bigInt(32);
return bigIntLayout;
}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display