Fix versions and exported types
This commit is contained in:
@@ -42,7 +42,7 @@
|
||||
"dependencies": {
|
||||
"@0x/orderbook": "^0.0.1",
|
||||
"@0x/assert": "^2.1.4",
|
||||
"@0x/connect": "^5.0.17",
|
||||
"@0x/connect": "^5.0.18",
|
||||
"@0x/contract-addresses": "^3.1.0",
|
||||
"@0x/contract-wrappers": "^12.0.0",
|
||||
"@0x/dev-utils": "^2.3.2",
|
||||
|
@@ -48,7 +48,6 @@ export {
|
||||
MarketSellSwapQuoteWithAffiliateFee,
|
||||
LiquidityForAssetData,
|
||||
OrdersAndFillableAmounts,
|
||||
OrderProvider,
|
||||
OrderProviderRequest,
|
||||
OrderProviderResponse,
|
||||
SignedOrderWithRemainingFillableMakerAssetAmount,
|
||||
|
@@ -28,17 +28,6 @@ export interface SignedOrderWithRemainingFillableMakerAssetAmount extends Signed
|
||||
remainingFillableMakerAssetAmount?: BigNumber;
|
||||
}
|
||||
|
||||
/**
|
||||
* gerOrdersAsync: Given an OrderProviderRequest, get an OrderProviderResponse.
|
||||
* getAvailableMakerAssetDatasAsync: Given a taker asset data string, return all availabled paired maker asset data strings.
|
||||
* getAvailableTakerAssetDatasAsync: Given a maker asset data string, return all availabled paired taker asset data strings.
|
||||
*/
|
||||
export interface OrderProvider {
|
||||
getOrdersAsync: (orderProviderRequest: OrderProviderRequest) => Promise<OrderProviderResponse>;
|
||||
getAvailableMakerAssetDatasAsync: (takerAssetData: string) => Promise<string[]>;
|
||||
getAvailableTakerAssetDatasAsync: (makerAssetData: string) => Promise<string[]>;
|
||||
}
|
||||
|
||||
/**
|
||||
* Represents the metadata to call a smart contract with calldata.
|
||||
* calldataHexString: The hexstring of the calldata.
|
||||
|
@@ -27,7 +27,7 @@
|
||||
"license": "Apache-2.0",
|
||||
"devDependencies": {
|
||||
"@0x/tslint-config": "^3.0.1",
|
||||
"@0x/types": "^2.4.1",
|
||||
"@0x/types": "^2.4.2",
|
||||
"@types/jest": "^24.0.17",
|
||||
"@types/sinon": "^2.2.2",
|
||||
"@types/websocket": "^0.0.39",
|
||||
@@ -38,10 +38,10 @@
|
||||
"typescript": "3.0.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"@0x/assert": "^2.1.4",
|
||||
"@0x/connect": "^5.0.17",
|
||||
"@0x/assert": "^2.1.5",
|
||||
"@0x/connect": "^5.0.18",
|
||||
"@0x/mesh-rpc-client": "^3.0.1-beta",
|
||||
"@0x/order-utils": "^8.3.0",
|
||||
"@0x/utils": "^4.5.0"
|
||||
"@0x/order-utils": "^8.3.1",
|
||||
"@0x/utils": "^4.5.1"
|
||||
}
|
||||
}
|
||||
|
@@ -74,9 +74,7 @@ export class MeshOrderProvider extends BaseOrderProvider {
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves the entire orderbook for the asset pair. If websocket is available
|
||||
* a subscription will be created to keep these orders up to date. If no websocket
|
||||
* connection is available calling this function will fetch orders from the SRA endpoint.
|
||||
* Creates a subscription for all asset pairs in Mesh.
|
||||
* @param makerAssetData the Maker Asset Data
|
||||
* @param takerAssetData the Taker Asset Data
|
||||
*/
|
||||
|
@@ -83,15 +83,15 @@ export class SRAWebsocketOrderProvider extends BaseSRAOrderProvider {
|
||||
}
|
||||
}
|
||||
const assetPairKey = OrderStore.getKeyForAssetPair(makerAssetData, takerAssetData);
|
||||
const subcriptionOpts = {
|
||||
const subscriptionOpts = {
|
||||
makerAssetData,
|
||||
takerAssetData,
|
||||
};
|
||||
this._wsSubscriptions.set(assetPairKey, subcriptionOpts);
|
||||
this._wsSubscriptions.set(assetPairKey, subscriptionOpts);
|
||||
// Subscribe to both sides of the book
|
||||
this._ordersChannel.subscribe(subcriptionOpts);
|
||||
this._ordersChannel.subscribe(subscriptionOpts);
|
||||
this._ordersChannel.subscribe({
|
||||
...subcriptionOpts,
|
||||
...subscriptionOpts,
|
||||
makerAssetData: takerAssetData,
|
||||
takerAssetData: makerAssetData,
|
||||
});
|
||||
|
Reference in New Issue
Block a user