mirror of
https://github.com/cerc-io/watcher-ts
synced 2026-09-10 09:44:08 +00:00
Import TICK_MIN from util and fix lint errors. (#187)
Co-authored-by: prathamesh0 <prathamesh.musale0@gmail.com>
This commit is contained in:
@@ -11,10 +11,16 @@ import {
|
||||
|
||||
export { abi as TESTERC20_ABI } from '../artifacts/test/contracts/TestERC20.sol/TestERC20.json';
|
||||
|
||||
const TICK_MIN = -887272;
|
||||
const TICK_MAX = 887272;
|
||||
export const getMinTick = (tickSpacing: number) => Math.ceil(TICK_MIN / tickSpacing) * tickSpacing;
|
||||
export const getMaxTick = (tickSpacing: number) => Math.floor(TICK_MAX / tickSpacing) * tickSpacing;
|
||||
export const TICK_MIN = -887272;
|
||||
export const TICK_MAX = 887272;
|
||||
|
||||
export const getMinTick = (tickSpacing: number): number => {
|
||||
return Math.ceil(TICK_MIN / tickSpacing) * tickSpacing;
|
||||
};
|
||||
|
||||
export const getMaxTick = (tickSpacing: number): number => {
|
||||
return Math.floor(TICK_MAX / tickSpacing) * tickSpacing;
|
||||
};
|
||||
|
||||
export const deployTokens = async (signer: Signer): Promise<{token0Address: string, token1Address: string}> => {
|
||||
const Token = new ethers.ContractFactory(TESTERC20_ABI, TESTERC20_BYTECODE, signer);
|
||||
|
||||
Reference in New Issue
Block a user