From cb8f4a3a4e378a749c6bbbddf46d8d79d35722cc Mon Sep 17 00:00:00 2001 From: Richard Moore Date: Tue, 25 Aug 2020 01:09:48 -0400 Subject: [PATCH] Updated docs for all packages on npm pages (#1013). --- packages/abi/README.md | 47 +++++++++++++++--- packages/abstract-provider/README.md | 53 +++++++++++++++++--- packages/abstract-signer/README.md | 29 ++++++++--- packages/address/README.md | 30 +++++++++--- packages/asm/README.md | 1 + packages/base64/README.md | 1 - packages/basex/README.md | 30 +++++++++++- packages/bignumber/README.md | 36 +++++++++++--- packages/bytes/README.md | 63 +++++++++++++++++++++--- packages/cli/README.md | 1 + packages/constants/README.md | 34 ++++++++++--- packages/contracts/README.md | 47 +++++++++++++++--- packages/hash/README.md | 29 ++++++++--- packages/hdnode/README.md | 35 ++++++++++--- packages/json-wallets/README.md | 42 +++++++++++++--- packages/keccak256/README.md | 24 ++++++--- packages/logger/README.md | 28 ++++++++++- packages/networks/README.md | 29 ++++++++--- packages/pbkdf2/README.md | 23 ++++++--- packages/properties/README.md | 39 ++++++++++++--- packages/providers/README.md | 73 +++++++++++++++++++++++++--- packages/random/README.md | 26 +++++++--- packages/rlp/README.md | 25 +++++++--- packages/sha2/README.md | 33 ++++++++++--- packages/shims/README.md | 10 +--- packages/signing-key/README.md | 27 +++++++++- packages/solidity/README.md | 26 +++++++--- packages/strings/README.md | 42 +++++++++++++--- packages/testcases/README.md | 9 ++-- packages/tests/README.md | 10 ++-- packages/transactions/README.md | 33 ++++++++++--- packages/units/README.md | 31 +++++++++--- packages/wallet/README.md | 27 +++++++--- packages/web/README.md | 34 ++++++++++--- packages/wordlists/README.md | 11 ++--- 35 files changed, 851 insertions(+), 187 deletions(-) diff --git a/packages/abi/README.md b/packages/abi/README.md index c3c158183..ded58c951 100644 --- a/packages/abi/README.md +++ b/packages/abi/README.md @@ -1,15 +1,50 @@ Ethereum ABI Coder ================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for encoding and decoding the Application Binary Interface (ABI) +used by most smart contracts to interoperate between other smart contracts and clients. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/abi/). -`@TODO` +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + ConstructorFragment, + EventFragment, + Fragment, + FunctionFragment, + ParamType, + FormatTypes, + + AbiCoder, + defaultAbiCoder, + + Interface, + Indexed, + + ///////////////////////// + // Types + + CoerceFunc, + JsonFragment, + JsonFragmentType, + + Result, + checkResultErrors, + + LogDescription, + TransactionDescription + +} = require("@ethersproject/abi"); +``` License ------- diff --git a/packages/abstract-provider/README.md b/packages/abstract-provider/README.md index 8010615a2..16ce8cc0b 100644 --- a/packages/abstract-provider/README.md +++ b/packages/abstract-provider/README.md @@ -1,15 +1,56 @@ Abstract Provider ================= -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for defining the common interface for a Provider, which in +ethers differs quite substantially from Web3.js. -API ---- +A Provider is an abstraction of non-account-based operations on a blockchain and +is generally not directly involved in signing transaction or data. -`@TODO` +For signing, see the [Abstract Signer](https://www.npmjs.com/package/@ethersproject/abstract-signer) +or [Wallet](https://www.npmjs.com/package/@ethersproject/wallet) sub-modules. + +For more information, see the [documentation](https://docs.ethers.io/v5/api/providers/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + Provider, + + ForkEvent, + BlockForkEvent, + TransactionForkEvent, + TransactionOrderForkEvent, + + // Types + BlockTag, + + Block, + BlockWithTransactions, + + TransactionRequest, + TransactionResponse, + TransactionReceipt, + + Log, + EventFilter, + + Filter, + FilterByBlockHash, + + EventType, + Listener + +} = require("@ethersproject/abstract-provider"); +``` License ------- diff --git a/packages/abstract-signer/README.md b/packages/abstract-signer/README.md index bf4277022..0e8be1acc 100644 --- a/packages/abstract-signer/README.md +++ b/packages/abstract-signer/README.md @@ -1,15 +1,32 @@ Abstract Signer =============== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is an abstraction of an Ethereum account, which may be backed by a [private key](https://www.npmjs.com/package/@ethersproject/wallet), +signing service (such as Geth or Parity with key managment enabled, or a +dedicated signing service such as Clef), +[hardware wallets](https://www.npmjs.com/package/@ethersproject/hardware-wallets), etc. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/signer/). -`@TODO` +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + Signer, + VoidSigner, + + // Types + ExternallyOwnedAccount + +} = require("@ethersproject/abstract-signer"); +``` License ------- diff --git a/packages/address/README.md b/packages/address/README.md index dbea4f2da..80e994d88 100644 --- a/packages/address/README.md +++ b/packages/address/README.md @@ -1,15 +1,33 @@ Ethereum Address Utilities ========================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for encoding, verifying and computing checksums for +Ethereum addresses and computing special addresses, such as those +enerated by and for contracts under various situations. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/address/). -`@TODO` +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + getAddress, + isAddress, + + getIcapAddress, + + getContractAddress, + getCreate2Address + +} = require("@ethersproject/address"); +``` License ------- diff --git a/packages/asm/README.md b/packages/asm/README.md index b1732ee77..6a8d6c820 100644 --- a/packages/asm/README.md +++ b/packages/asm/README.md @@ -205,6 +205,7 @@ Building If you make changes to the `grammar.jison` file, make sure to run the `npm generate` command to re-build the AST parser. + License ======= diff --git a/packages/base64/README.md b/packages/base64/README.md index 7e4a07fdd..9c7d50548 100644 --- a/packages/base64/README.md +++ b/packages/base64/README.md @@ -29,7 +29,6 @@ console.log(encodedData); // "..." ``` - License ======= diff --git a/packages/basex/README.md b/packages/basex/README.md index db64b85c6..b5217d1c9 100644 --- a/packages/basex/README.md +++ b/packages/basex/README.md @@ -1,5 +1,31 @@ -Base X +Base-X ====== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). +It is responsible for encoding and decoding vinary data in arbitrary bases, but +is primarily for Base58 encoding which is used for various blockchain data. + +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/encoding/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + BaseX, + + Base32, + Base58 + +} = require("@ethersproject/basex"); +``` + +License +------- + +MIT License diff --git a/packages/bignumber/README.md b/packages/bignumber/README.md index 1d1b8bb2d..9d1932573 100644 --- a/packages/bignumber/README.md +++ b/packages/bignumber/README.md @@ -1,15 +1,39 @@ Big Numbers =========== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for handling arbitrarily large numbers and mathematic operations. -API ---- +For more information, see the documentation for [Big Numbers](https://docs.ethers.io/v5/api/utils/bignumber/) +and [Fixed-Point Numbers](https://docs.ethers.io/v5/api/utils/fixednumber/). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + BigNumber, + + FixedFormat, + FixedNumber, + + formatFixed, + + parseFixed + + // Types + + BigNumberish + +} = require("@ethersproject/bignumber"); +``` -`@TODO` License ------- diff --git a/packages/bytes/README.md b/packages/bytes/README.md index 0616e29a6..865325e1f 100644 --- a/packages/bytes/README.md +++ b/packages/bytes/README.md @@ -1,15 +1,62 @@ -Byte Manipulation Libraries -=========================== +Byte Manipulation +================= -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for manipulating binary data. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/bytes/). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + isBytesLike, + isBytes, + + arrayify, + + concat, + + stripZeros, + zeroPad, + + isHexString, + hexlify, + + hexDataLength, + hexDataSlice, + hexConcat, + + hexValue, + + hexStripZeros, + hexZeroPad, + + splitSignature, + joinSignature, + + // Types + + Bytes, + BytesLike, + + DataOptions, + + Hexable, + + SignatureLike, + Signature + +} = require("@ethersproject/bytes"); +``` -`@TODO` License ------- diff --git a/packages/cli/README.md b/packages/cli/README.md index 2611cd585..d68c0a500 100644 --- a/packages/cli/README.md +++ b/packages/cli/README.md @@ -12,6 +12,7 @@ and debug Ethereum-related tasks using the ethers.js library. ----- + Sandbox Utility =============== diff --git a/packages/constants/README.md b/packages/constants/README.md index 327559c8d..4018a6901 100644 --- a/packages/constants/README.md +++ b/packages/constants/README.md @@ -1,15 +1,37 @@ Etehreum Constants ================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains many frequently used constants when dealing with Ethereum. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/constants/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + AddressZero, + HashZero, + + EtherSymbol, + + NegativeOne, + Zero, + One, + Two, + + WeiPerEther, + MaxUint256 + +} = require("@ethersproject/constants"); +``` -`@TODO` License ------- diff --git a/packages/contracts/README.md b/packages/contracts/README.md index f8d0aaf91..0af4985e6 100644 --- a/packages/contracts/README.md +++ b/packages/contracts/README.md @@ -1,15 +1,50 @@ Ethereum Contract Meta-Class ============================ -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is creating (at run-time) an object which interacts with an on-chain +contract as a native JavaScript object. -API ---- +If you are familiar with ORM for Databases, this is similar, but for smart contracts. + +For more information, see the [documentation](https://docs.ethers.io/v5/api/contract/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + Contract, + ContractFactory, + + RunningEvent, + + // Types + + ContractInterface, + + Overrides, + PayableOverrides, + CallOverrides, + + PopulatedTransaction, + + EventFilter, + + ContractFunction, + + Event, + ContractReceipt, + ContractTransaction + +} = require("@ethersproject/contract"); +``` -`@TODO` License ------- diff --git a/packages/hash/README.md b/packages/hash/README.md index c2a48b211..fde1d644d 100644 --- a/packages/hash/README.md +++ b/packages/hash/README.md @@ -1,15 +1,32 @@ Etheruem Hash Utilities ======================= -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains several common hashing utilities (but not the actual hash functions). -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/hashing/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + isValidName, + namehash, + + id, + + messagePrefix, + hashMessage + +} = require("@ethersproject/hash"); +``` -`@TODO` License ------- diff --git a/packages/hdnode/README.md b/packages/hdnode/README.md index eb8597b9f..f61ba72c7 100644 --- a/packages/hdnode/README.md +++ b/packages/hdnode/README.md @@ -1,15 +1,38 @@ Hierarchal Deterministic Utilities (BIP32) ========================================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible computing, deriving, encoding and decoding Hierarchal-Deterministic +private keys. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/hdnode/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + HDNode, + + defaultPath, + + mnemonicToSeed, + mnemonicToEntropy, + entropyToMnemonic, + isValidMnemonic, + + // Types + + Mnemonic + +} = require("@ethersproject/hdnode"); +``` -`@TODO` License ------- diff --git a/packages/json-wallets/README.md b/packages/json-wallets/README.md index 9531cc324..f46048465 100644 --- a/packages/json-wallets/README.md +++ b/packages/json-wallets/README.md @@ -1,15 +1,45 @@ Secret Storage JSON Wallet Utilities ==================================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for encoding, decoding, encrypting and decrypting JSON wallet +formats. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + isCrowdsaleWallet, + decryptCrowdsale, + + isKeystoreWallet, + decryptKeystore, + decryptKeystoreSync, + encryptKeystore, + + getJsonWalletAddress, + + decryptJsonWallet, + decryptJsonWalletSync, + + // Types + + ProgressCallback, + + EncryptOptions + +} = require("@ethersproject/json-wallets"); +``` -`@TODO` License ------- diff --git a/packages/keccak256/README.md b/packages/keccak256/README.md index d2021a496..bc9da6482 100644 --- a/packages/keccak256/README.md +++ b/packages/keccak256/README.md @@ -1,15 +1,27 @@ KECCAK256 Hash Function ======================= -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for the identify function (i.e. KECCAK256) use in Ethereum. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/hashing/#utils-keccak256). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + keccak256 + +} = require("@ethersproject/keccak256"); +``` -`@TODO` License ------- diff --git a/packages/logger/README.md b/packages/logger/README.md index 911a0f8ab..114b2fdee 100644 --- a/packages/logger/README.md +++ b/packages/logger/README.md @@ -1,7 +1,33 @@ Logger ====== -@TODO: +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). + +It is responsible for managing logging and errors to maintain a standard +structure. + +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/logger/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + Logger, + + // Enums + + ErrorCode, + + LogLevel, + +} = require("@ethersproject/logger"); +``` + License ------- diff --git a/packages/networks/README.md b/packages/networks/README.md index 92e05b02d..1b93a51e1 100644 --- a/packages/networks/README.md +++ b/packages/networks/README.md @@ -1,15 +1,32 @@ Ethereum (and ilk) Network Definitions ====================================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for tracking common networks along with important +parameters for each. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/providers/types/#providers-Network). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + getNetwork, + + // Types + + Network, + Networkish + +} = require("@ethersproject/networks"); +``` -`@TODO` License ------- diff --git a/packages/pbkdf2/README.md b/packages/pbkdf2/README.md index cd2c61e0a..722c23c35 100644 --- a/packages/pbkdf2/README.md +++ b/packages/pbkdf2/README.md @@ -1,15 +1,26 @@ Password-Based Key Derivation Function 2 (pbkdf2) ================================================= -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains the PBKDF2 function. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + pbkdf2 + +} = require("@ethersproject/pbkdf2"); +``` -`@TODO` License ------- diff --git a/packages/properties/README.md b/packages/properties/README.md index 1f82cfe60..a31e298f1 100644 --- a/packages/properties/README.md +++ b/packages/properties/README.md @@ -1,15 +1,42 @@ Property Utilities ================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains several useful utility methods for managing simple objects with +defined properties. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/properties/). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + defineReadOnly, + + getStatic, + + resolveProperties, + checkProperties, + + shallowCopy, + deepCopy, + + Description, + + // Types + + Deferrable + +} = require("@ethersproject/properties"); +``` -`@TODO` License ------- diff --git a/packages/providers/README.md b/packages/providers/README.md index 8b28057b4..c267a5851 100644 --- a/packages/providers/README.md +++ b/packages/providers/README.md @@ -1,15 +1,76 @@ Ethereum Providers ================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains common Provider classes, utility functions for dealing with providers +and re-exports many of the classes and types needed implement a custom Provider. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/providers/). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + Provider, + BaseProvider, + + JsonRpcProvider, + StaticJsonRpcProvider, + UrlJsonRpcProvider, + + FallbackProvider, + + AlchemyProvider, + CloudflareProvider, + EtherscanProvider, + InfuraProvider, + NodesmithProvider, + + IpcProvider, + + Web3Provider, + + WebSocketProvider, + + JsonRpcSigner, + + getDefaultProvider, + + getNetwork, + + Formatter, + + // Types + + TransactionReceipt, + TransactionRequest, + TransactionResponse, + + Listener, + + ExternalProvider, + + Block, + BlockTag, + EventType, + Filter, + Log, + + JsonRpcFetchFunc, + + Network, + Networkish + +} = require("@ethersproject/providers"); +``` -`@TODO` License ------- diff --git a/packages/random/README.md b/packages/random/README.md index f04a4efbd..0ab374396 100644 --- a/packages/random/README.md +++ b/packages/random/README.md @@ -1,15 +1,29 @@ Random Value Utilities ====================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains functions to assist with random numbers. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/bytes/#byte-manipulation--random-bytes). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + shuffled, + + randomBytes + +} = require("@ethersproject/random"); +``` -`@TODO` License ------- diff --git a/packages/rlp/README.md b/packages/rlp/README.md index 1693604f1..bffb36322 100644 --- a/packages/rlp/README.md +++ b/packages/rlp/README.md @@ -1,15 +1,28 @@ Recursive-Length Prefix Coder ============================= -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains functions for encoding and decoding RLP data. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/encoding/#rlp--methods). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + encode, + decode + +} = require("@ethersproject/rlp"); +``` -`@TODO` License ------- diff --git a/packages/sha2/README.md b/packages/sha2/README.md index fce94ac48..901e51f98 100644 --- a/packages/sha2/README.md +++ b/packages/sha2/README.md @@ -1,15 +1,36 @@ SHA2 Hash Functions =================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It is responsible for common cryptographic hashes and HMAC. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/hashing/). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + ripemd160, + + sha256, + sha512, + + computeHmac, + + // Enums + + SupportedAlgorithm + +} = require("@ethersproject/sha2"); +``` -`@TODO` License ------- diff --git a/packages/shims/README.md b/packages/shims/README.md index e341bd270..701538fbb 100644 --- a/packages/shims/README.md +++ b/packages/shims/README.md @@ -1,15 +1,7 @@ Compatibility Shims (for constrained environments) ================================================== -**EXPERIMENTAL** - -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. - -API ---- - -`@TODO` +Common shims to fix incomplete environments. License ------- diff --git a/packages/signing-key/README.md b/packages/signing-key/README.md index b756558bb..dbd6a021d 100644 --- a/packages/signing-key/README.md +++ b/packages/signing-key/README.md @@ -1,5 +1,30 @@ Signing Key =========== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). +It is responsible for secp256-k1 signing, verifying and recovery operations. + +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/signing-key/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + SigningKey, + + computePublicKey, + recoverPublicKey + +} = require("@ethersproject/signing-key"); +``` + +License +------- + +MIT License diff --git a/packages/solidity/README.md b/packages/solidity/README.md index a8b9e7084..a15f1ec5e 100644 --- a/packages/solidity/README.md +++ b/packages/solidity/README.md @@ -1,15 +1,29 @@ Solidity Packed-Encoding Utilities ================================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains functions to perform Solidity-specific packed (i.e. non-standard) +encoding operations. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/hashing/#utils--solidity-hashing). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + pack, + keccak256, + sha256 + +} = require("@ethersproject/solidity"); +``` -`@TODO` License ------- diff --git a/packages/strings/README.md b/packages/strings/README.md index 4b556cfdd..f00aaa4e0 100644 --- a/packages/strings/README.md +++ b/packages/strings/README.md @@ -1,15 +1,45 @@ String Manipulation Utilities ============================= -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains functions to safely convert between UTF-8 data, strings and Bytes32 strings +(i.e. "short strings"). -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/strings/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + toUtf8Bytes, + toUtf8CodePoints, + toUtf8String, + + formatBytes32String, + parseBytes32String, + + nameprep + + // Enums + + Utf8ErrorFuncs, + Utf8ErrorReason, + + UnicodeNormalizationForm + + // Types + + Utf8ErrorFunc, + +} = require("@ethersproject/strings"); +``` -`@TODO` License ------- diff --git a/packages/testcases/README.md b/packages/testcases/README.md index 1c6306a31..9cb97afe6 100644 --- a/packages/testcases/README.md +++ b/packages/testcases/README.md @@ -1,15 +1,12 @@ Testcases for Ethereum ====================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains the testcases used to verify various Ethereum operations. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/testing/). -`@TODO` License ------- diff --git a/packages/tests/README.md b/packages/tests/README.md index dd1985d3e..9b36ac7e4 100644 --- a/packages/tests/README.md +++ b/packages/tests/README.md @@ -1,15 +1,11 @@ Mocha Test Suite for Ethers =========================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains the tests to verify ethers is working correctly. -API ---- - -`@TODO` +For more information, see the [documentation](https://docs.ethers.io/v5/testing/). License ------- diff --git a/packages/transactions/README.md b/packages/transactions/README.md index 3ed096c2f..63099df6e 100644 --- a/packages/transactions/README.md +++ b/packages/transactions/README.md @@ -1,15 +1,36 @@ Ethereum Transaction Utilities ============================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains various functions for encoding and decoding serialized transactios. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/transactions/). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + computeAddress, + recoverAddress, + + serialize, + parse, + + // Types + + Transaction, + UnsignedTransaction + +} = require("@ethersproject/abi"); +``` -`@TODO` License ------- diff --git a/packages/units/README.md b/packages/units/README.md index bc3633540..140220fc6 100644 --- a/packages/units/README.md +++ b/packages/units/README.md @@ -1,15 +1,34 @@ Ethereum Unit Conversion Utilities ================================== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains functions to convert between string representations and numeric +representations of numbers, including those out of the range of JavaScript. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/display-logic/). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + formatUnits, + parseUnits, + + formatEther, + parseEther, + + commify + +} = require("@ethersproject/units"); +``` -`@TODO` License ------- diff --git a/packages/wallet/README.md b/packages/wallet/README.md index ea997424e..d6fea3ed3 100644 --- a/packages/wallet/README.md +++ b/packages/wallet/README.md @@ -1,15 +1,30 @@ Ethereum Wallet =============== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains the class to manage a private key and signing for a standard +externally-owned account. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/signer/#Wallet). + + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + Wallet, + + verifyMessage + +} = require("@ethersproject/wallet"); +``` -`@TODO` License ------- diff --git a/packages/web/README.md b/packages/web/README.md index 16efcd0c4..5ed09d142 100644 --- a/packages/web/README.md +++ b/packages/web/README.md @@ -1,15 +1,37 @@ Web Utilities ============= -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +It contains functions to abstract safely and responsibly connecting to the web, +including exponential back-off. -API ---- +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/web/). + +Importing +--------- + +Most users will prefer to use the [umbrella package](https://www.npmjs.com/package/ethers), +but for those with more specific needs, individual components can be imported. + +```javascript +const { + + fetchJson, + + poll, + + // Types + ConnectionInfo, + FetchJsonResponse, + + PollOptions, + OncePollable, + OnceBlockable + +} = require("@ethersproject/web"); +``` -`@TODO` License ------- diff --git a/packages/wordlists/README.md b/packages/wordlists/README.md index a752ea3fd..ac3cec441 100644 --- a/packages/wordlists/README.md +++ b/packages/wordlists/README.md @@ -1,9 +1,10 @@ BIP39 Wordlists =============== -**EXPERIMENTAL** +This sub-module is part of the [ethers project](https://github.com/ethers-io/ethers.js). Supported Languages: + - **en** - English - **es** - Spanish - **fr** - French @@ -13,13 +14,8 @@ Supported Languages: - **zh_cn** - Chinese (simplified) - **zh_tw** - Chinese (traditional) -Please see the [ethers](https://github.com/ethers-io/ethers.js) repository -for more informations. +For more information, see the [documentation](https://docs.ethers.io/v5/api/utils/wordlists/). -API ---- - -`@TODO` Browser ------- @@ -28,7 +24,6 @@ In the browser distribution file, only the English word list is included in the root `ethers` pacakge. To include additional word lists, they must be added using additional `