Skip to content

A simple, maximally extensible, dependency minimized framework for building modern Ethereum dApps

License

Notifications You must be signed in to change notification settings

Uniswap/web3-react

Repository files navigation

web3-react 🧰

CI

Warning: alpha code!

Tasks:

  • Other Connectors
    • WalletLink
    • WalletConnect V2
    • Gnosis Safe
    • Frame
    • Other injected connectors?
  • Address remaining TODOs in the code
  • Tests
  • Ensure dist/ files can be consumed in e.g. CRA
  • Host example/ on CodeSandbox
  • Work on DevEx
  • Docs
  • Upgrade to Node 16 once LTS

Packages

Details
Package @alpha Version Size Description
@web3-react/store npm minzip
@web3-react/types npm minzip
@web3-react/core npm minzip
Connectors
@web3-react/network npm minzip
@web3-react/metamask npm minzip
@web3-react/walletconnect npm minzip

Getting Started

  • yarn
  • yarn bootstrap
  • yarn start

In addition to compiling each package in watch mode, this will also spin up an example app on http://localhost:3000/.

Running Tests

  • yarn test --watch

Useful Commands

Add a dependency

  • yarn lerna add <DEPENDENCY> --scope <SUBPACKAGE>

Remove a dependency

  • Delete the relevant package.json entry

Because of a lerna bug, it's not possible to prune yarn.lock programmatically, so regenerate it manually:

  • yarn lerna exec 'rm -f yarn.lock' --scope SUBPACKAGE
  • yarn clean --scope SUBPACKAGE
  • yarn bootstrap

Publishing

  • yarn lerna publish

Note that because packages/example is set to private, sibling dependencies in packages/example/package.json are not updated during publishing, and must be manually bumped.