EOSIO / eosjs

General purpose library for the EOSIO blockchain.
http://eosio.github.io/eosjs
MIT License
1.43k stars 463 forks source link

Codes ran correct on Ubuntu and didn't run on MacOS #182

Closed leeduckgo closed 6 years ago

leeduckgo commented 6 years ago

The codes are as follows:

EOS = require("eosjs");
eosconfig = {
    chainId: "aca376f206b8fc25a6ed44dbdc66547c36c6c33e3a119ffbeaef943642f0e906",
    httpEndpoint: 'https://mainnet.genereos.io',
};
const eos = new EOS(eosconfig);
eos.getProducers(true, undefined, 200).then(result => { console.log(result) });

The version of Nodejs/npm/eosjs are the same. mac_eosjs ubuntu_eosjs

jcalfee commented 6 years ago

Instead of new EOS use EOS()