Skip to content
This repository has been archived by the owner on Jul 9, 2021. It is now read-only.

Commit

Permalink
Merge pull request #159 from 0xProject/fix/types
Browse files Browse the repository at this point in the history
Move Aftifact type definition to 'types'
  • Loading branch information
LogvinovLeon authored Sep 7, 2017
2 parents b5435b6 + af217e3 commit 4e22c28
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 9 deletions.
1 change: 1 addition & 0 deletions src/artifacts.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import {Artifact} from './types';
import * as TokenArtifact from './artifacts/Token.json';
import * as ExchangeArtifact from './artifacts/Exchange.json';
import * as EtherTokenArtifact from './artifacts/EtherToken.json';
Expand Down
2 changes: 1 addition & 1 deletion src/contract_wrappers/contract_wrapper.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as _ from 'lodash';
import * as Web3 from 'web3';
import {Web3Wrapper} from '../web3_wrapper';
import {ZeroExError} from '../types';
import {ZeroExError, Artifact} from '../types';
import {utils} from '../utils/utils';

export class ContractWrapper {
Expand Down
7 changes: 0 additions & 7 deletions src/globals.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,6 @@ declare module '*.json' {
/* tslint:enable */
}

declare interface Artifact {
abi: any;
networks: {[networkId: number]: {
address: string;
}};
}

// find-version declarations
declare function findVersions(version: string): string[];
declare module 'find-versions' {
Expand Down
7 changes: 7 additions & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -412,3 +412,10 @@ export interface LogWithDecodedArgs extends Web3.LogEntry, DecodedArgs {}
export interface TransactionReceiptWithDecodedLogs extends Web3.TransactionReceipt {
logs: Array<LogWithDecodedArgs|Web3.LogEntry>;
}

export interface Artifact {
abi: any;
networks: {[networkId: number]: {
address: string;
}};
}
2 changes: 1 addition & 1 deletion src/web3_wrapper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import * as _ from 'lodash';
import * as Web3 from 'web3';
import * as BigNumber from 'bignumber.js';
import promisify = require('es6-promisify');
import {ZeroExError} from './types';
import {ZeroExError, Artifact} from './types';
import {Contract} from './contract';

export class Web3Wrapper {
Expand Down

0 comments on commit 4e22c28

Please sign in to comment.