Skip to content

Latest commit

 

History

History
58 lines (38 loc) · 813 Bytes

README.md

File metadata and controls

58 lines (38 loc) · 813 Bytes

Bytom.js

This is the Bytom [JavaScript API][docs]

You need to run a bytom/bycoin environment to use this library.

Installation

Node

npm install bytom.js

Usage

// in node.js
var bytomJS = require('bytom.js');

var bytomJS = new bytomJS('http//remote-node');
console.log(bytomJS);

Additionally you can set a provider using bytomJS.setProvider() :

bytomJS.setProvider('http//remote-node');

Building

Requirements

sudo apt-get update
sudo apt-get install nodejs
sudo apt-get install npm

Building

Build only the bytom.js package:

npm run build

This will put all the browser build files into the dist folder.

Testing (mocha)

npm test