DEPRECATED - Solidity Project Contracts Core Library
Deprecation notice
This repository is now deprecated and not maintained any longer. Use the new Animoca's Solidity libraries instead:
- Core contracts: https://github.com/animoca/ethereum-contracts
- Assets bridging contracts: https://github.com/animoca/ethereum-contracts-bridging
- Project template: https://github.com/animoca/template-ethereum-contracts
Introduction
This project serves as a base dependency for Solidity-based smart contract projects by providing common dependencies, configurations, contracts, scripts, interfaces, constants, and testing utilities.
This project uses hardhat and augments it with a set of plugins aimed at providing a comprehensive and robust development and testing pipeline.
Table of Contents
Overview
Installation
Install as a module dependency in your host NodeJS project:
npm install @animoca/ethereum-contracts-core --save-dev
npm install hardhat --save-dev
or
yarn add -D @animoca/ethereum-contracts-core
yarn add -D hardhat
Usage
Commands
yarn
yarn run-all
See package.json scripts for detailed commands.
Solidity Contracts
Import dependency contracts into your Solidity contracts and derive as needed:
import "@animoca/ethereum-contracts-core/contracts/{{Contract Group}}/{{Contract}}.sol"
Test and Migration Scripts
Require the NodeJS module dependency in your test and migration scripts as needed:
const { constants, interfaces, behaviors } = require("@animoca/ethereum-contracts-core");