Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
interface
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
LuckySwap
interface
Commits
78581d54
Unverified
Commit
78581d54
authored
Oct 06, 2021
by
Justin Domingue
Committed by
GitHub
Oct 06, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
improve routing types (#2507)
parent
896f2fc3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
23 deletions
+22
-23
types.ts
src/state/routing/types.ts
+22
-23
No files found.
src/state/routing/types.ts
View file @
78581d54
import
{
Token
}
from
'
@uniswap/sdk-core
'
export
enum
V3TradeState
{
LOADING
,
INVALID
,
...
...
@@ -6,39 +8,36 @@ export enum V3TradeState {
SYNCING
,
}
export
type
TokenInRoute
=
Pick
<
Token
,
'
address
'
|
'
chainId
'
|
'
symbol
'
|
'
decimals
'
>
export
type
PoolInRoute
=
{
type
:
'
v3-pool
'
address
:
string
tokenIn
:
TokenInRoute
tokenOut
:
TokenInRoute
sqrtRatioX96
:
string
liquidity
:
string
tickCurrent
:
string
fee
:
string
amountIn
?:
string
amountOut
?:
string
}
export
interface
GetQuoteResult
{
quoteId
?:
string
blockNumber
:
string
amount
:
string
amountDecimals
:
string
gasPriceWei
:
string
gasUseEstimate
:
string
gasUseEstimateQuote
:
string
gasUseEstimateQuoteDecimals
:
string
gasUseEstimateUSD
:
string
methodParameters
:
{
calldata
:
string
;
value
:
string
}
methodParameters
?
:
{
calldata
:
string
;
value
:
string
}
quote
:
string
quoteDecimals
:
string
quoteGasAdjusted
:
string
quoteGasAdjustedDecimals
:
string
quoteId
:
string
route
:
{
address
:
string
amountIn
?:
string
amountOut
?:
string
fee
:
string
liquidity
:
string
sqrtRatioX96
:
string
tickCurrent
:
string
tokenIn
:
{
address
:
string
chainId
:
number
decimals
:
string
|
number
symbol
?:
string
}
tokenOut
:
{
address
:
string
chainId
:
number
decimals
:
string
|
number
symbol
?:
string
}
}[][]
route
:
PoolInRoute
[][]
routeString
:
string
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment