Infura: Build dApp Frontends with Infura, React, and IPFS
Learn how to build dApp Frontends with Infura, React, and IPFS
What is Infura?
1. First, we need a Filebase IPFS bucket.
2. Select ‘Buckets’ from the left side bar menu, or navigate to console.filebase.com/buckets.

3. Enter a bucket name and choose the IPFS storage network to create the bucket.

4. Next, open a command line prompt and create a new project directory:
5. Initiate your NPM environment and install the Create React App and OpenZeppelin NetworkJS packages:
6. Now let’s create the initial version of our dApp using a common React boilerplate called create-react-app:
create-react-app:7. Next, login to the Infura.io console. Create a new project.

8. Select the Ethereum network, and give your project a name.

9. In the Project settings, select "Ropsten” from the endpoint dropdown menu.

10. Then, take down the Project ID. You will need this in the next step.

11. In your project directory, navigate into the client directory that was created automatically by the create-react-app client command, and open the src/App.js file.
create-react-app client command, and open the src/App.js file.12. Start your app by using the npm start command while within the ./client directory of your project.
npm start command while within the ./client directory of your project.
13. In the ./client/src directory, create a new directory called components, and inside that directory create a file called Web3Data.js with the following content:
./client/src directory, create a new directory called components, and inside that directory create a file called Web3Data.js with the following content:14. Open the ./client/src/App.js file and replace the existing content with the following code, which includes a new function to use the Web3Data.js script we just created:
./client/src/App.js file and replace the existing content with the following code, which includes a new function to use the Web3Data.js script we just created:15. Start your dApp again with the npm start command.

16. From here, you can style your app using a .css file and image files.
.css file and image files.
17. From here, we can upload a .css theme file, and we’ll also upload an image file.

18. Then, edit your App.js file to include these IPFS Files:
Last updated