This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import web3 from "@solana/web3.js"; | |
| import * as BufferLayout from "@solana/buffer-layout"; | |
| import QuickLRU from "quick-lru"; | |
| //////////////////////////////////////////////////////////////////////////////// | |
| export class BorshBoolean extends BufferLayout.Layout<boolean> { | |
| constructor(property?: string) { | |
| super(1, property); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| use std::str::FromStr as _; | |
| use solana_client::{ | |
| client_error::{ClientError, ClientErrorKind}, | |
| rpc_client::GetConfirmedSignaturesForAddress2Config, | |
| rpc_request::RpcRequest, | |
| }; | |
| use solana_program::pubkey::Pubkey; | |
| use solana_sdk::commitment_config::CommitmentConfig; | |
| use solext::rpc::{Client as _, GetAllSignaturesForAddress as _, GetMarkerSignature as _}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // --- `@solana/web3.js` v1 --- | |
| import web3 from '@solana/web3.js'; | |
| (async (rpcUrl: string) => { | |
| const rpc = new web3.Connection(rpcUrl); | |
| const subject = new web3.PublicKey('j1oAbxxiDUWvoHxEDhWE7THLjEkDQW2cSHYn2vttxTF'); | |
| const signatures = await rpc.getSignaturesForAddress(subject, { | |
| limit: 1000, | |
| }, 'finalized'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import web3 from "@solana/web3.js"; | |
| import * as BufferLayout from "@solana/buffer-layout"; | |
| import bs58 from "bs58"; | |
| ////////////////////////////////////////////////// | |
| class BorshString extends BufferLayout.Layout<string> { | |
| constructor(property?: string) { | |
| super(-1, property); | |
| } |