April 2017
Intermediate to advanced
266 pages
7h 4m
English
To interact with a package's artifacts within JavaScript code, you simply need to require that package's .json files and then use truffle-contract to turn them into usable abstractions:
var contract = require("truffle-contract"); var data = require("example-truffle-library/build/contracts/SimpleNameRegistry.json"); var SimpleNameRegistry = contract(data);
Read now
Unlock full access