Skip to content

CrazyDream000/ton-swap-contract

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tonswap - FunC Smart Contracts

TonSwap is live on TON mainnet.

TonSwap is currently live on the TON mainnet and is in beta, so please use it at your own risk.

Overview

TonSwap is a decentralized exchange (DEX) and automated market maker (AMM) that utilizes the Uniswap V2 curve, a financial model commonly used by popular AMMs like PancakeSwap, QuickSwap, and Sushi. This platform enables traders to swap tokens and allows liquidity providers to supply liquidity and earn rewards.

Develop

run npm install

Compile contract and run tests

This project depends on the executables fift, func . You can build them from source, or you can download the pre compiled binaries.

Func Compiler

This project utilizes the latest features of the FunC programming language, including #include and const, so please ensure you are using the latest FunC compiler. If you want to set a specific func path, you can do so by using the FUNC_PATH environment variable export FUNC_PATH=/usr/local/bin/func

Run tests

the project uses ton-contract-executor package to run Jest based tests. Use npm run test to execute the test suite.

Run TVM-BUS tests

run npm run test-bus this tests are different then the tests in /test/amm-minter.spec.ts, Because this tests are using ton-tvm-bus , each tests starts in a single message, and the message passing between contracts is done automatically, messages with statInit are auto deployed , messages find their receiver automatically unlike in the first test suite.

Run end to end test on Mainnet or Testnet

npm run e2e (this process will generate a deploy wallet during it`s execution)

build for web

npm run build:web - this process will generate json files with hex value for the contract, both for amm-minter.fc and amm-wallet.fc;

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published