easy-solc

Simple wrapper for solc.

Usage no npm install needed!

<script type="module">
  import easySolc from 'https://cdn.skypack.dev/easy-solc';
</script>

README

easy-solc

Simple wrapper for solc.

const TestContract = `
pragma solidity 0.5.11;

contract Test {
  function hello() public view returns (uint256) {
    return 55;
  }
}
`
const { abi, bytecode, deployedBytecode } = await easySolc('Test', TestContract);
/* or */
const { abi, bytecode, deployedBytecode } = await easySolc({ sources: { content: TestContract } });