Skip to content

Latest commit

 

History

History
63 lines (39 loc) · 3.17 KB

File metadata and controls

63 lines (39 loc) · 3.17 KB

The representative of web3 is Etherum.

about Solidity language

memory and storage keywords.

function keyword

View public private external internal

common concepts

eth

1.block

2.tokens

3.smart contract

4.gas

about web3js package

0.introduction

Web3.js is a robust and flexible collection of libraries for TypeScript and JavaScript developers. It allows you to interact with a local or remote Ethereum node (or any EVM-compatible blockchain) using HTTP, IPC or WebSocket. It serves as an essential tool for connecting and crafting applications within the Ethereum ecosystem.

1. Here is an overview of the available packages

  • ABI: The web3-eth-abi package simplifies decoding logs and parameters, encoding function calls and signatures, and inferring types for efficient Ethereum contract interactions.

  • Accounts: The web3-eth-accounts package has tools for creating Ethereum accounts/wallets and making sure transactions and data are securely signed.

  • Contract: With the web3-eth-Contract, you can interact with Smart contracts. This functionality allows communication with contracts through JavaScript or TypeScript objects, simplifying your development and interaction processes.

  • ENS: The web3-eth-ens package helps you communicate with the Ethereum Name Service (ENS) on the blockchain.

  • Iban: The web3-eth-iban package allows you to switch between Ethereum addresses and special banking-like addresses (IBAN or BBAN). It makes the conversion back and forth easier.

  • Net: The web3-net class allows you to talk about and deal with an Ethereum node's network details.

  • Personal: Use web3-eth-personal for direct communication with the Ethereum node about your accounts, streamlining account management in your development workflow. NOTE: For enhanced security when interacting with public nodes, consider using web3-eth-accounts for local signing operations, keeping your private keys and sensitive information secure on your local machine

  • Utils: With the web3-utils package you can perform a range of essential tasks in Ethereum development, including converting data formats, checking addresses, encoding and decoding, hashing, handling numbers, and much more, providing versatile utility functions for your applications.

  • Web3Eth: The web3-eth is your main tool for interacting with the Ethereum blockchain. It's like the control center for managing your interactions with Ethereum.

2.import relative package.

if you only need specific packages, it is recommended to install the specific required packages (e.g, if you want the contract package npm i web3-eth-contract instead)

3.concept of provider

You must initialize the Web3 object with a provider, otherwise, you won't be able to fully use web3.js functionalities.

you should know how to add a provider.

4.

solana

solana is very fast solana/web3js

solana/web3.js

connection status

native

on chain

keypair