2.0.1 • Published 11 months ago

@mooncatrescue/contracts v2.0.1

Weekly downloads
-
License
AGPL-3.0
Repository
gitlab
Last release
11 months ago

A collection of smart contract templates, for working with existing infrastructure contracts in the MoonCatRescue ecosystem.

Usage

To add this module to an existing Node.js application:

npm install --save @mooncatrescue/contracts

Then within a Solidity contract, you can import an interface by referencing it like this:

// SPDX-License-Identifier: AGPL-3.0
pragma solidity ^0.8.9;

import { IMoonCatRescue } from "@mooncatrescue/contracts/IMoonCatRescue.sol";

Within a Hardhat script or test file, the moonCatUtils helper library can be imported like:

const { network, ethers } = require('hardhat'),
  { disperseMoonCats } = require('@mooncatrescue/contracts/moonCatUtils');

async function main() {
  await disperseMoonCats(1000, 1004, 5); // Give one MoonCat to the first five addresses
  await disperseMoonCats(5050, 5059, 2); // Give five more MoonCats to the first two addresses
}

main()
  .then(() => process.exit(0))
  .catch(error => {
    console.error(error);
    process.exit(1);
  });
2.0.1

11 months ago

1.3.0

1 year ago

2.0.0

1 year ago

1.2.1

2 years ago

1.2.0

2 years ago

1.1.1

2 years ago

1.1.0

2 years ago

1.1.4

2 years ago

1.1.3

2 years ago

1.1.2

2 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago