This repo contains all of the smart contracts used to run Baguette.
Factory address: 0xBB6e8C136ca537874a6808dBFC5DaebEd9a57554
Router address: 0xC386631E7D35c7231bE146b14cf4430b4A524F8A
These contracts are compiled and deployed using Hardhat. They can also be run using the Remix IDE. A tutorial for using Remix is located here.
To prepare the dev environment, run yarn install
. To compile the contracts, run yarn compile
. Yarn is available to install here if you need it.
If you need to use any of the contract ABIs, you can install this repo as an npm package with npm install --dev @baguette-exchange/contracts
. Then import the ABI like so: import { abi as IBaguettePairABI } from '@baguette-exchange/contracts/artifacts/contracts/baguette-core/interfaces/IBaguettePair.sol/IBaguettePair.json'
.
These contracts were adapted from these Uniswap repos: uniswap-v2-core, uniswap-v2-periphery, and uniswap-lib.