1.1.4 • Published 2 years ago

@positionex/posi-token v1.1.4

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

Position Token

Position token smart contract is a mixture of RFI tokenomics with the added function of mint and burn.

Staking Contract with Vesting Schedule

To use Vesting Schedule:

  1. Import this package by npm i @positionex/posi-token --save dev
  2. Import & extend VestingScheduleBase from @positionex/posi-token
  3. Use _addSchedules method to add vesting schedules Eg.
  4. Override _transferLockedToken method to transfer locked tokens

Example:

    function _transferLockedToken(address _to, uint192 _amount) internal override {
        _rewardERC20.transfer(_to, uint256(_amount)); 
    }

Example: See PosiStakingManagerV2.sol

Note: You can override _addSchedules method to modify vesting schedule.

Architecture

See VestingScheduleBase.sol