This is the Harmony javascript library which provides an easier way to interact with Harmony's blockchain.
This libraries contains a few packages.
- @harmony-js/core
- @harmony-js/account
- @harmony-js/crypto
- @harmony-js/network
- @harmony-js/utils
- @harmony-js/transaction
- @harmony-js/contract
- @harmony-js/staking
This library works on both nodejs and browser. Please use it according to your use case.
- Nodejs: 10.0+
- Browser: Latest Chrome and Firefox
Note: we added a @next tag to npm package, please use the following command to install with npm/yarn
# npm
npm install @harmony-js/core@next
# yarn
yarn add @harmony-js/core@next
# tslib is required, we'd better install it as well
npm install tslib
yarn add tslib
yarn global add lerna && yarn global add typescript
yarn bootstrap
Build umd
and esm
version javascript for each sub-packages, which can be accessed by import
or require
yarn dist
All files are exported in packages/dist
folder, use **.esm.js
or **.umd.js
format
yarn test:src
-
.env
file defines configuration, edit if you have custom settings -
Run harmony node locally, follow the instructions: https://github.com/harmony-one/harmony
-
Wait for 1-2 mins, and run this:
yarn build && yarn test:e2e