diff options
author | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-09-26 20:55:52 +0800 |
---|---|---|
committer | Leonid Logvinov <logvinov.leon@gmail.com> | 2018-09-26 20:55:52 +0800 |
commit | 5d73eebf6abe52763ea6984f85102157abea5b6c (patch) | |
tree | 8cec1c58fe22ba62d979dbc1c6ff366e81985b8d /packages/asset-buyer/src/constants.ts | |
parent | f3deabccf4e6caec57351a09f82b3f786122b5ea (diff) | |
parent | 13aa98f0f3431e4ea4db07794a06304c237e8d45 (diff) | |
download | dexon-sol-tools-5d73eebf6abe52763ea6984f85102157abea5b6c.tar dexon-sol-tools-5d73eebf6abe52763ea6984f85102157abea5b6c.tar.gz dexon-sol-tools-5d73eebf6abe52763ea6984f85102157abea5b6c.tar.bz2 dexon-sol-tools-5d73eebf6abe52763ea6984f85102157abea5b6c.tar.lz dexon-sol-tools-5d73eebf6abe52763ea6984f85102157abea5b6c.tar.xz dexon-sol-tools-5d73eebf6abe52763ea6984f85102157abea5b6c.tar.zst dexon-sol-tools-5d73eebf6abe52763ea6984f85102157abea5b6c.zip |
Merge branch 'development' into feature/ts-ethers
Diffstat (limited to 'packages/asset-buyer/src/constants.ts')
-rw-r--r-- | packages/asset-buyer/src/constants.ts | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/packages/asset-buyer/src/constants.ts b/packages/asset-buyer/src/constants.ts new file mode 100644 index 000000000..79b5d9052 --- /dev/null +++ b/packages/asset-buyer/src/constants.ts @@ -0,0 +1,20 @@ +import { BigNumber } from '@0xproject/utils'; + +import { BuyQuoteRequestOpts } from './types'; + +const DEFAULT_BUY_QUOTE_REQUEST_OPTS: BuyQuoteRequestOpts = { + feePercentage: 0, + shouldForceOrderRefresh: false, + slippagePercentage: 0.2, // 20% slippage protection +}; + +export const constants = { + ZERO_AMOUNT: new BigNumber(0), + NULL_ADDRESS: '0x0000000000000000000000000000000000000000', + MAINNET_NETWORK_ID: 1, + DEFAULT_ORDER_REFRESH_INTERVAL_MS: 10000, // 10 seconds + ETHER_TOKEN_DECIMALS: 18, + DEFAULT_BUY_QUOTE_REQUEST_OPTS, + MAX_PER_PAGE: 10000, + DEFAULT_EXPIRY_BUFFER_SECONDS: 15, +}; |