Web 3.JS Adapters
The @solana/web3.js library is currently widely used in the Solana ecosystem and defines its own types for public keys, transactions, instructions, etc.
npm install @metaplex-foundation/umi-web3js-adapters// For public keys.
fromWeb3JsPublicKey(myWeb3JsPublicKey)
toWeb3JsPublicKey(myUmiPublicKey)
// For keypairs.
fromWeb3JsKeypair(myWeb3JsKeypair)
toWeb3JsKeypair(myUmiKeypair)
// For transactions.
fromWeb3JsTransaction(myWeb3JsTransaction)
toWeb3JsTransaction(myUmiTransaction)
fromWeb3JsLegacyTransaction(myLegacyWeb3JsTransaction)
toWeb3JsLegacyTransaction(myUmiTransaction)
// For transaction messages.
fromWeb3JsMessage(myWeb3JsTransactionMessage)
toWeb3JsMessage(myUmiTransactionMessage)
toWeb3JsMessageFromInput(myUmiTransactionInput)
// For instructions.
fromWeb3JsInstruction(myWeb3JsInstruction)
toWeb3JsInstruction(myUmiInstruction)Last updated