0

I have web3.js working on my Windows machine, I need to access web3 library called coder.js, according to this answer the location of that library is web3/lib/solidity/coder.js

But I cannot find these libraries, does anyone know what is the location on web3 libraries on Windows 7?

q9f
  • 32,913
  • 47
  • 156
  • 395
SwapnilKumbhar
  • 763
  • 1
  • 11
  • 31
  • 1
    You are checking in the web3 node module only right. I have downloaded web3 module and checked it is present there. Try reinstalling the node module. – joifsi Jun 02 '17 at 08:00
  • Yes checking in node module only I have found one file there named "coder.js" but it was actually a HTML file that means the file is "coder.js.html", but cant find the js file – SwapnilKumbhar Jun 02 '17 at 09:18
  • 1
    What I see is a js file. The link to the js file of node module in github is https://github.com/ethereum/web3.js/blob/develop/lib/solidity/coder.js Try removing the node module and reinstalling it. – joifsi Jun 02 '17 at 09:55
  • yes I too got that file on git hub but cant find it on my machine, I will try reinstalling it hopefully it works – SwapnilKumbhar Jun 02 '17 at 10:33
  • 1
    If you have installed web3 using npm, then you have a folder node_modules, inside that folder there's the web3 folder. – Ismael Jun 02 '17 at 21:10

1 Answers1

1

Answering my own question there are multiple instances of the file at locations

1.

C:\Users\user1\node_modules\web3\lib\solidity

2.

C:\Users\User1\AppData\Roaming\npm\node_modules\truffle\node_modules\ethpm-registry\node_modules\truffle-contract\node_modules\web3\lib\solidity

3.

`C:\Users\User1\AppData\Roaming\npm\node_modules\truffle\node_modules\truffle-migrate\node_modules\truffle-contract\node_modules\web3\lib\solidity`

4.

C:\Users\User(LPT-APR2015-02)\AppData\Roaming\npm\node_modules\truffle\node_modules\web3\lib\solidity

And there are some more, But I think the correct one to use is first in the list.

we can use this coder.js to parse the transaction log. Ref:- How do I parse the transaction receipt log with web3.js?

SwapnilKumbhar
  • 763
  • 1
  • 11
  • 31