Blockexplorers give us the ability to view lots of different information about the blockchain including data about:
- the blockchain network itself
- blocks in the blockchain
- transactions in a block
- accounts
- and many other things
Etherscan is a good example of an Ethereum blockexplorer.
Clone this project to pull down some basic starter code.
After that cd into the base directory of the project and run npm install
to download all the project dependencies.
The AlchemySDK was used for this project
You can find lots of good docs on the AlchemySDK here:
Alright, without further ado, let's get started!
Create a unique Alchemy API Mainnet key for your project as described here.
Create an empty .env
file in the base directory of this project.
Add the following line to the .env
file replacing YOUR_ALCHEMY_API_KEY
with your api key.
REACT_APP_ALCHEMY_API_KEY=YOUR_ALCHEMY_API_KEY
Do not remove the REACT_APP_
prefix. React uses that to import env variables.
npm start
Running the command above will run the app in the development mode. Open http://localhost:3000 to view it in your browser.