Web3.js DApp Development – How to Create Offline Accounts and Sign Transactions

blockchainclientsdapp-developmentethereumjsweb3js

I have a question about Ethereum client-side, maybe someone could give a hint…

It's about building a DApp, we need a web client capable of creating offline a private key and a public key, and also send signed transactions to an Ethereum node.

After investigating for a while we came to the conclusion this is possible through the web3.js library (and others like ethereumjs), but it implies using nodejs and browserfy, right? The question is:

Is there any other simpler solution, such as using a simple js file?

Thx in advance!

Best Answer

You are making a wrong assumption. Using Web3.js does not require Browserify or Node.JS. You can drop in web3.js dependency in HTML code like any other JavaScript library. Only building Web3.js distribution requires this build toolchain.

Here is a simple "index.html" application using web3.js.

Related Topic