@ethronjs/plugin.eth.ganache

0.2.0 • Public • Published

@ethronjs/plugin.eth.ganache

NPM version Total downloads

Ethron.js plugin for Ganache blockchain.

Developed in Dogma, compiled to JavaScript.

Engineered in Valencia, Spain, EU by EthronLabs.

Use

const ganache = require("@ethronjs/plugin.eth.ganache")

ganache.start()

Start ganache-cli:

async function ganache.start(opts:object)
  • opts (object), the start options:
    • host (string), the host. Default: 127.0.0.1.
    • port (number), the port. Default: 8545.
    • acct (object), the prefunded accounts.
      • prefunded (number or array), the prefunded accounts. When array, each item represents an account: {prvKey, balance}.
      • file (string), the file where to save the prefunded account data.
    • db (string), the database dir path.
    • blockTime (number), the block interval. When not set, a block is issued for every transaction.
    • networkId (number), the network id.
    • gas (object), the gas data.
      • price (number), the gas price in wei.
      • limit (number), the gas limit in wei.

ganache.stop()

Stop ganache-cli started previously with start():

async function ganache.stop()

Readme

Keywords

none

Package Sidebar

Install

npm i @ethronjs/plugin.eth.ganache

Weekly Downloads

3

Version

0.2.0

License

none

Unpacked Size

6.69 kB

Total Files

6

Last publish

Collaborators

  • ethronjs