michael-spengler / wwi18seac

9 stars 9 forks source link

Ethereum Support in Deno #8

Open michael-spengler opened 4 years ago

michael-spengler commented 4 years ago

Draft some solution proposals on how to ideally establish a reliable Ethereum Support in the Deno Context.

Related open issues:

  1. https://github.com/trufflesuite/truffle/issues/3307
  2. https://github.com/ethereum/web3.js/issues/3700
michael-spengler commented 4 years ago

https://medium.com/samsung-internet-dev/using-node-modules-in-deno-2885600ed7a9

dance-planner commented 4 years ago

https://stackoverflow.com/questions/61821038/how-to-use-npm-module-in-deno

michael-spengler commented 4 years ago

Applicants for this funded task please mention some examples on how you provided deeply nested node packages as deno modules.

e.g. based on solution proposals like https://stackoverflow.com/questions/61821038/how-to-use-npm-module-in-deno or https://jspm.org/ ...

nanspro commented 4 years ago

@michael-spengler I am interested in the funded bounty but haven't applied yet. I explored the web3.js a little and saw that they have already converted part of their code into typescript, perhaps anyone can pick it up from there. https://www.skypack.dev/ seems better than jspm imo as it is an upgraded version of pika CDN which had 2million+ packages supported. So perhaps web3 dependencies can be imported from node through skypack and converted to a full deno module. If you look at https://docs.skypack.dev/code/deno

Skypack automatically converts legacy npm packages to modern ESM and polyfills some common Node.js built-in modules that they might depend on.
However, some modules (like the "fs" file system API) cannot be polyfilled and thus can't run on Deno (or anywhere outside of Node.js). Any packages on npm that rely on these dependencies won't run on Deno.
- fs
- crypto
- http
- https

I believe that deno has support for http/https, fs already. I couldn't find a crypto module though but if it's not present then there is already a polyfilled crypto module which can be used https://www.skypack.dev/npm/@peculiar/webcrypto

michael-spengler commented 4 years ago

@nanspro Thank You for your interest. I just saw your comment. This sounds good. There is one other fellow whom I got to know yesterday who looked into the topic already.

Perhaps the two of you can team up and share the bounty. The funder is Scott Moore from Consensys / GitCoin and I can imagine that some more fruitful collaborations can emerge from this.

I just invited you as a collaborator to https://github.com/michael-spengler/web3 which is the repo behind https://deno.land/x/web3

Let me know if you need anything from my side. And feel free to join: https://discord.gg/deno.

Sounds good?

nanspro commented 4 years ago

Sounds good @michael-spengler I joined the discord and DM'd you there. So the bounty of 1 ETH, it was to write a proposal to do this right? Not the actual implementation I suppose cause that'll take more time I guess. If that's the case is the bounty done or do we need to do something else also?

michael-spengler commented 4 years ago

@nanspro Thank you for your message. Of course I meant solution proposals in form of code. Otherwise it would be an inflationary use of ETH from my perspective. I'll make this even clearer in the future.

michael-spengler commented 4 years ago

I'll create a discord group with you, the other applicant and the funder.

nanspro commented 4 years ago

Hey @michael-spengler yeah the issue description was less clear to me. Make sense now. I'll coordinate on discord with you guys