Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/howardpen9/staking-in-tact
Staking Jetton token(ERC20 in TON) implement in Tact-lang
https://github.com/howardpen9/staking-in-tact
func tact ton ton-blockchain
Last synced: 30 days ago
JSON representation
Staking Jetton token(ERC20 in TON) implement in Tact-lang
- Host: GitHub
- URL: https://github.com/howardpen9/staking-in-tact
- Owner: howardpen9
- Created: 2023-06-29T17:23:09.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-11-23T07:58:52.000Z (about 1 year ago)
- Last Synced: 2023-11-23T14:45:28.514Z (about 1 year ago)
- Topics: func, tact, ton, ton-blockchain
- Language: TypeScript
- Homepage:
- Size: 236 KB
- Stars: 3
- Watchers: 1
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Example of Jetton Token Staking
```bash
yarn test # To test contract
yarn build # To build contract
yarn deploy # To deploy contract
yarn d1 # To run 1_Transfer_Stake, that transfers stake from one jetton wallet to the staking contract
yarn d2 # Generate the link to run 2_Stake, that enable for user to stakes jettons(based on the walletV4 contract address you gave to)
```## Deployment
To deploy contract you should:
1. Specify `contract.tact` that will be used as entry point of your contract
2. Configure `contract.deploy.ts` according to your `contract.tact` to generate a deployment link. In particular, it is necessary to correctly call the Init() function from the contract.If you renamed `contract.tact` to something else, you need to update `tact.config.json` correspondingly. For more information , see [Tact Documentation](https://docs.tact-lang.org/language/guides/config)
## Testing
Example of contract tests are in `contract.spec.ts`. For more information about testing, see [Tact Documentation](https://docs.tact-lang.org/language/guides/debug)
To add new test files to contract you should create `*.spec.ts` files similar to template's one and they would be automatically included in testing.
## Licence
MIT