3

Is it somehow possible to build the front-end side for a DApp using React ?

(if i have the back-end code written in solidity and i have no knowledge of solidity? or do i need to learn solidity first )

1

I am proposing you to check out Truffle's drizzle,it will help you to setup easily a react front end for your contract. Moreover, there is a template project available as a truffle box.

have a look at truffle drizzle's box you might install it then edit the code to get it works with your contract.

https://truffleframework.com/boxes/drizzle

NB: You don't necessarily need to have a prior knowledge about solidity. but you have to know how to deploy a contract and some details about the transactions (gas, fees,..)

1

It depends what your goal is. If you are interested in moving all the responsibility of writing data to some database from the server over to the client.

The client would need to get more intelligent and more functionality built into it.

In the past, a traditional web application could send HTML document with no JavaScript and we could make use of plain HTML form submittal to allow users to change data.

With Ethereum, if you want to make the client responsible for changing data in the application, then you need to use libraries and technologies that are focused on putting more business logic on the client-side of the application. React is perfect for this.

React makes writing complex business logic on the browser side much easier. So if your goal, your purpose of using React is what I mentioned above, then yes, you definitely can and I recommend you do so.

0

You need to know some JavaScript to use Web3 library to interact with contracts, Solidity knowledge is not really needed for front-end.

0

Yes of course. You can integrate Web3 and React in your dApp. You can read some nice tutorials about that searching "Web3 react" on Google. One of the most simple one that comes to my mind is "Create a Simple Decentralized Application with React" by Sheng Yang Liu on Medium.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.