Coder Social home page Coder Social logo

darrylyeo / scaffold-balancer Goto Github PK

View Code? Open in Web Editor NEW

This project forked from balancer/scaffold-balancer

0.0 1.0 0.0 15.58 MB

License: MIT License

Shell 2.56% JavaScript 5.81% TypeScript 81.23% CSS 1.00% Dockerfile 0.69% Less 0.15% Solidity 8.55%

scaffold-balancer's Introduction

๐Ÿ— Scaffold-Balancer

everything you need to build on Balancer! ๐Ÿš€

๐Ÿงช Quickly experiment with custom AMMs using a frontend that allows you to interact with your custom pool contract(s).

๐Ÿงช Fork mainnet ethereum and test your custom pools within the context of all available liquidity.

๐Ÿ— Build and test your Smart Order Router (SOR) extension, getting you one step closer to being integrated into the Balancer ecosystem.

Features

This project is a fork of scaffold-eth-typescript with a focus on providing tools to enable fast development of custom AMMs built on balancer. Write your contract, deploy it locally, and immediately have an interface to start to interact with the pool (swap/join/exit) both in isolation and in the context of all available balancer vault liquidity.

  • Pool Contracts UI - This helper UI allows you to interact directly with any (custom or existing) pool contract in real time.
  • Smart order router (SOR) playground - See how your custom pool stacks up against available balancer liquidity via the SOR playground.
  • Batch Swap - A UI for building arbitrarily complex batch swaps.

๐Ÿ„โ€โ™‚๏ธ Quick Start

Prerequisites: Node (v16) plus Yarn (v1.x) and Git

1๏ธโƒฃ clone/fork ๐Ÿ— scaffold-balancer:

git clone https://github.com/balancer/scaffold-balancer.git

2๏ธโƒฃ Install all necessary dependencies

yarn install

3๏ธโƒฃ Create scaffold config

yarn create-config

4๏ธโƒฃ Create Mnemonics for contract deployments

yarn generate && yarn account

5๏ธโƒฃ start your ๐Ÿ‘ทโ€ Hardhat fork of mainnet ethereum:

yarn fork

6๏ธโƒฃ in a second terminal window, ๐Ÿ›ฐ deploy your contract:

โš ๏ธIncluding deploys on yarn fork sometimes causes gas price issues. So, deployments are disabled and should be done separately.

yarn deploy

7๏ธโƒฃ generate frontend files for deployed contracts:

yarn contracts:build

8๏ธโƒฃ in a third terminal window, start your ๐Ÿ“ฑ frontend:

yarn dev

๐Ÿ” Edit your smart contract YourCustomPool.sol in packages/solidity-ts/contracts

๐Ÿ’ผ Edit your contract deployment scripts in packages/solidity-ts/deploy

๐Ÿ“ Edit your frontend in packages/nextjs-app-ts/src

๐Ÿ’ป Open http://localhost:3000 to see the app

scaffold-balancer's People

Contributors

shravansunder avatar danielmkm avatar joaobrunoah avatar technophile-04 avatar shravansunderxero avatar dvinubius avatar carletex avatar grothem avatar chrisipk avatar kamikazebr avatar harts avatar codenamejason avatar johnnylambada avatar tonisives avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.