├── .eslintignore ├── .eslintrc.js ├── .gitattributes ├── .github └── workflows │ └── ci.yml ├── .gitignore ├── .prettierrc ├── .solcover.js ├── .solhint.json ├── LICENSE ├── README.md ├── codechecks.yml ├── contracts ├── FlashBorrower.sol ├── aave │ ├── AaveERC3156.sol │ ├── interfaces │ │ ├── ATokenLike.sol │ │ ├── AaveFlashBorrowerLike.sol │ │ ├── LendingPoolAddressesProviderLike.sol │ │ └── LendingPoolLike.sol │ ├── libraries │ │ └── AaveDataTypes.sol │ └── mocks │ │ ├── ATokenMock.sol │ │ ├── LendingPoolAddressesProviderMock.sol │ │ └── LendingPoolMock.sol ├── dydx │ ├── DYDXERC3156.sol │ ├── interfaces │ │ ├── DYDXFlashBorrowerLike.sol │ │ └── SoloMarginLike.sol │ ├── libraries │ │ └── DYDXDataTypes.sol │ └── mocks │ │ └── SoloMarginMock.sol ├── interfaces │ └── IERC20.sol ├── mocks │ └── ERC20Mock.sol ├── uniswap │ ├── UniswapERC3156.sol │ ├── interfaces │ │ ├── UniswapV2FactoryLike.sol │ │ ├── UniswapV2FlashBorrowerLike.sol │ │ └── UniswapV2PairLike.sol │ └── mocks │ │ ├── UniswapV2FactoryMock.sol │ │ └── UniswapV2PairMock.sol └── yield │ ├── YieldDaiERC3156.sol │ ├── YieldFYDaiERC3156.sol │ ├── interfaces │ ├── IFYDai.sol │ ├── IPool.sol │ └── YieldFlashBorrowerLike.sol │ ├── libraries │ ├── Math64x64.sol │ ├── SafeCast.sol │ ├── YieldMath.sol │ └── YieldMathWrapper.sol │ └── mocks │ ├── FYDaiMock.sol │ └── Pool.sol ├── deploy ├── AaveERC3156.js ├── DYDXERC3156.js ├── FlashBorrower.js ├── UniswapERC3156.js ├── YieldDaiERC3156-args-1.js ├── YieldDaiERC3156-args-42.js ├── YieldDaiERC3156.js └── YieldFYDaiERC3156.js ├── hardhat.config.js ├── package.json ├── test ├── 03_DYDXERC3156.test.js ├── 04_AaveERC3156.test.js ├── 05_YieldFYDaiERC3156.test.js └── 07_UniswapERC3156.test.js ├── tsconfig.json ├── utils └── ganache.sh └── yarn.lock /.eslintignore: -------------------------------------------------------------------------------- 1 | dist 2 | node_modules 3 | coverage 4 | -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/.eslintrc.js -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | *.sol linguist-language=Solidity 2 | -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/.github/workflows/ci.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/.gitignore -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/.prettierrc -------------------------------------------------------------------------------- /.solcover.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/.solcover.js -------------------------------------------------------------------------------- /.solhint.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/.solhint.json -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/README.md -------------------------------------------------------------------------------- /codechecks.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/codechecks.yml -------------------------------------------------------------------------------- /contracts/FlashBorrower.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/FlashBorrower.sol -------------------------------------------------------------------------------- /contracts/aave/AaveERC3156.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/AaveERC3156.sol -------------------------------------------------------------------------------- /contracts/aave/interfaces/ATokenLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/interfaces/ATokenLike.sol -------------------------------------------------------------------------------- /contracts/aave/interfaces/AaveFlashBorrowerLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/interfaces/AaveFlashBorrowerLike.sol -------------------------------------------------------------------------------- /contracts/aave/interfaces/LendingPoolAddressesProviderLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/interfaces/LendingPoolAddressesProviderLike.sol -------------------------------------------------------------------------------- /contracts/aave/interfaces/LendingPoolLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/interfaces/LendingPoolLike.sol -------------------------------------------------------------------------------- /contracts/aave/libraries/AaveDataTypes.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/libraries/AaveDataTypes.sol -------------------------------------------------------------------------------- /contracts/aave/mocks/ATokenMock.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/mocks/ATokenMock.sol -------------------------------------------------------------------------------- /contracts/aave/mocks/LendingPoolAddressesProviderMock.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/mocks/LendingPoolAddressesProviderMock.sol -------------------------------------------------------------------------------- /contracts/aave/mocks/LendingPoolMock.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/aave/mocks/LendingPoolMock.sol -------------------------------------------------------------------------------- /contracts/dydx/DYDXERC3156.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/dydx/DYDXERC3156.sol -------------------------------------------------------------------------------- /contracts/dydx/interfaces/DYDXFlashBorrowerLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/dydx/interfaces/DYDXFlashBorrowerLike.sol -------------------------------------------------------------------------------- /contracts/dydx/interfaces/SoloMarginLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/dydx/interfaces/SoloMarginLike.sol -------------------------------------------------------------------------------- /contracts/dydx/libraries/DYDXDataTypes.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/dydx/libraries/DYDXDataTypes.sol -------------------------------------------------------------------------------- /contracts/dydx/mocks/SoloMarginMock.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/dydx/mocks/SoloMarginMock.sol -------------------------------------------------------------------------------- /contracts/interfaces/IERC20.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/interfaces/IERC20.sol -------------------------------------------------------------------------------- /contracts/mocks/ERC20Mock.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/mocks/ERC20Mock.sol -------------------------------------------------------------------------------- /contracts/uniswap/UniswapERC3156.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/uniswap/UniswapERC3156.sol -------------------------------------------------------------------------------- /contracts/uniswap/interfaces/UniswapV2FactoryLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/uniswap/interfaces/UniswapV2FactoryLike.sol -------------------------------------------------------------------------------- /contracts/uniswap/interfaces/UniswapV2FlashBorrowerLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/uniswap/interfaces/UniswapV2FlashBorrowerLike.sol -------------------------------------------------------------------------------- /contracts/uniswap/interfaces/UniswapV2PairLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/uniswap/interfaces/UniswapV2PairLike.sol -------------------------------------------------------------------------------- /contracts/uniswap/mocks/UniswapV2FactoryMock.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/uniswap/mocks/UniswapV2FactoryMock.sol -------------------------------------------------------------------------------- /contracts/uniswap/mocks/UniswapV2PairMock.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/uniswap/mocks/UniswapV2PairMock.sol -------------------------------------------------------------------------------- /contracts/yield/YieldDaiERC3156.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/YieldDaiERC3156.sol -------------------------------------------------------------------------------- /contracts/yield/YieldFYDaiERC3156.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/YieldFYDaiERC3156.sol -------------------------------------------------------------------------------- /contracts/yield/interfaces/IFYDai.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/interfaces/IFYDai.sol -------------------------------------------------------------------------------- /contracts/yield/interfaces/IPool.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/interfaces/IPool.sol -------------------------------------------------------------------------------- /contracts/yield/interfaces/YieldFlashBorrowerLike.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/interfaces/YieldFlashBorrowerLike.sol -------------------------------------------------------------------------------- /contracts/yield/libraries/Math64x64.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/libraries/Math64x64.sol -------------------------------------------------------------------------------- /contracts/yield/libraries/SafeCast.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/libraries/SafeCast.sol -------------------------------------------------------------------------------- /contracts/yield/libraries/YieldMath.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/libraries/YieldMath.sol -------------------------------------------------------------------------------- /contracts/yield/libraries/YieldMathWrapper.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/libraries/YieldMathWrapper.sol -------------------------------------------------------------------------------- /contracts/yield/mocks/FYDaiMock.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/mocks/FYDaiMock.sol -------------------------------------------------------------------------------- /contracts/yield/mocks/Pool.sol: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/contracts/yield/mocks/Pool.sol -------------------------------------------------------------------------------- /deploy/AaveERC3156.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/deploy/AaveERC3156.js -------------------------------------------------------------------------------- /deploy/DYDXERC3156.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/deploy/DYDXERC3156.js -------------------------------------------------------------------------------- /deploy/FlashBorrower.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/deploy/FlashBorrower.js -------------------------------------------------------------------------------- /deploy/UniswapERC3156.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/deploy/UniswapERC3156.js -------------------------------------------------------------------------------- /deploy/YieldDaiERC3156-args-1.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/deploy/YieldDaiERC3156-args-1.js -------------------------------------------------------------------------------- /deploy/YieldDaiERC3156-args-42.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/deploy/YieldDaiERC3156-args-42.js -------------------------------------------------------------------------------- /deploy/YieldDaiERC3156.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/deploy/YieldDaiERC3156.js -------------------------------------------------------------------------------- /deploy/YieldFYDaiERC3156.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/deploy/YieldFYDaiERC3156.js -------------------------------------------------------------------------------- /hardhat.config.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/hardhat.config.js -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/package.json -------------------------------------------------------------------------------- /test/03_DYDXERC3156.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/test/03_DYDXERC3156.test.js -------------------------------------------------------------------------------- /test/04_AaveERC3156.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/test/04_AaveERC3156.test.js -------------------------------------------------------------------------------- /test/05_YieldFYDaiERC3156.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/test/05_YieldFYDaiERC3156.test.js -------------------------------------------------------------------------------- /test/07_UniswapERC3156.test.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/test/07_UniswapERC3156.test.js -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/tsconfig.json -------------------------------------------------------------------------------- /utils/ganache.sh: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/utils/ganache.sh -------------------------------------------------------------------------------- /yarn.lock: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alcueca/ERC3156-Wrappers/HEAD/yarn.lock --------------------------------------------------------------------------------