diff options
Diffstat (limited to 'packages/web3-wrapper')
-rw-r--r-- | packages/web3-wrapper/CHANGELOG.json | 18 | ||||
-rw-r--r-- | packages/web3-wrapper/package.json | 21 | ||||
-rw-r--r-- | packages/web3-wrapper/src/index.ts | 47 | ||||
-rw-r--r-- | packages/web3-wrapper/src/monorepo_scripts/postpublish.ts | 8 | ||||
-rw-r--r-- | packages/web3-wrapper/src/monorepo_scripts/stage_docs.ts | 8 | ||||
-rw-r--r-- | packages/web3-wrapper/src/web3_wrapper.ts | 1 |
6 files changed, 69 insertions, 34 deletions
diff --git a/packages/web3-wrapper/CHANGELOG.json b/packages/web3-wrapper/CHANGELOG.json index 422059cc0..b9cde2f95 100644 --- a/packages/web3-wrapper/CHANGELOG.json +++ b/packages/web3-wrapper/CHANGELOG.json @@ -1,5 +1,23 @@ [ { + "version": "2.0.0", + "changes": [ + { + "note": + "Export types: `BlockParam`, `TxData`, `Provider`, `TransactionReceipt`, `Transaction`, `TraceParams`, `TransactionTrace``, BlockWithoutTransactionDat`a, `LogEntry`, `FilterObject`, `CallData`, `TransactionReceiptWithDecodedLogs`, `BlockWithTransactionData``, LogTopi`c, `JSONRPCRequestPayload`, `TransactionReceiptStatus`, `DecodedLogArgs`, `StructLog`, `JSONRPCErrorCallback``, BlockParamLitera`l, `ContractEventArg`, `DecodedLogEntry`, `LogEntryEvent`, `OpCode`, `TxDataPayable`, `JSONRPCResponsePayload``, RawLogEntr`y, `DecodedLogEntryEvent`, `LogWithDecodedArgs`, `AbiDefinition`, `RawLog`, `FunctionAbi`, `EventAbi`, `EventParameter``, MethodAb`i, `ConstructorAbi`, `FallbackAbi`, `DataItem`, `ConstructorStateMutability` and `StateMutability`", + "pr": 924 + }, + { + "note": "Stop exporting types: `CallTxDataBaseRPC` and `AbstractBlockRPC`", + "pr": 924 + }, + { + "note": "Export `AbiDecoder` class", + "pr": 924 + } + ] + }, + { "version": "1.2.0", "changes": [ { diff --git a/packages/web3-wrapper/package.json b/packages/web3-wrapper/package.json index d672db7e4..3b347ac6f 100644 --- a/packages/web3-wrapper/package.json +++ b/packages/web3-wrapper/package.json @@ -9,8 +9,8 @@ "types": "lib/src/index.d.ts", "scripts": { "watch_without_deps": "tsc -w", - "build": "tsc && copyfiles -u 3 './lib/src/monorepo_scripts/**/*' ./scripts", - "clean": "shx rm -rf lib scripts", + "build": "tsc", + "clean": "shx rm -rf lib generated_docs", "lint": "tslint --project .", "test": "yarn run_mocha", "rebuild_and_test": "run-s clean build test", @@ -18,21 +18,11 @@ "run_mocha": "mocha --require source-map-support/register --require make-promises-safe lib/test/**/*_test.js --bail --exit", "test:coverage": "nyc npm run test --all && yarn coverage:report:lcov", "coverage:report:lcov": "nyc report --reporter=text-lcov > coverage/lcov.info", - "manual:postpublish": "yarn build; node ./scripts/postpublish.js", - "docs:stage": "node scripts/stage_docs.js", - "docs:json": "typedoc --excludePrivate --excludeExternals --target ES5 --json $JSON_FILE_PATH $PROJECT_FILES", - "upload_docs_json": "aws s3 cp generated_docs/index.json $S3_URL --profile 0xproject --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers --content-type application/json" + "docs:json": "typedoc --excludePrivate --excludeExternals --target ES5 --json $JSON_FILE_PATH $PROJECT_FILES" }, "config": { "postpublish": { - "docPublishConfigs": { - "extraFileIncludes": [ - "../types/src/index.ts", - "../ethereum-types/src/index.ts" - ], - "s3BucketPath": "s3://doc-jsons/web3-wrapper/", - "s3StagingBucketPath": "s3://staging-doc-jsons/web3-wrapper/" - } + "assets": [] } }, "license": "Apache-2.0", @@ -45,7 +35,6 @@ }, "homepage": "https://github.com/0xProject/0x-monorepo/packages/web3-wrapper/README.md", "devDependencies": { - "@0xproject/monorepo-scripts": "^1.0.5", "@0xproject/tslint-config": "^1.0.5", "@types/lodash": "4.14.104", "chai": "^4.0.1", @@ -60,7 +49,7 @@ "nyc": "^11.0.1", "shx": "^0.2.2", "tslint": "5.11.0", - "typedoc": "0xProject/typedoc", + "typedoc": "0.12.0", "typescript": "3.0.1" }, "dependencies": { diff --git a/packages/web3-wrapper/src/index.ts b/packages/web3-wrapper/src/index.ts index 5d3d135e4..7cdd25e55 100644 --- a/packages/web3-wrapper/src/index.ts +++ b/packages/web3-wrapper/src/index.ts @@ -1,11 +1,54 @@ export { Web3Wrapper } from './web3_wrapper'; export { marshaller } from './marshaller'; + +export { AbiDecoder } from '@0xproject/utils'; + +export { + BlockParam, + TxData, + Provider, + TransactionReceipt, + Transaction, + TraceParams, + TransactionTrace, + BlockWithoutTransactionData, + LogEntry, + FilterObject, + CallData, + TransactionReceiptWithDecodedLogs, + BlockWithTransactionData, + LogTopic, + JSONRPCRequestPayload, + TransactionReceiptStatus, + DecodedLogArgs, + StructLog, + JSONRPCErrorCallback, + BlockParamLiteral, + ContractEventArg, + DecodedLogEntry, + LogEntryEvent, + OpCode, + TxDataPayable, + JSONRPCResponsePayload, + RawLogEntry, + DecodedLogEntryEvent, + LogWithDecodedArgs, + AbiDefinition, + RawLog, + FunctionAbi, + EventAbi, + EventParameter, + MethodAbi, + ConstructorAbi, + FallbackAbi, + DataItem, + ConstructorStateMutability, + StateMutability, +} from 'ethereum-types'; export { Web3WrapperErrors, NodeType, CallDataRPC, - CallTxDataBaseRPC, - AbstractBlockRPC, BlockWithoutTransactionDataRPC, BlockWithTransactionDataRPC, TransactionRPC, diff --git a/packages/web3-wrapper/src/monorepo_scripts/postpublish.ts b/packages/web3-wrapper/src/monorepo_scripts/postpublish.ts deleted file mode 100644 index dcb99d0f7..000000000 --- a/packages/web3-wrapper/src/monorepo_scripts/postpublish.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { postpublishUtils } from '@0xproject/monorepo-scripts'; - -import * as packageJSON from '../package.json'; -import * as tsConfigJSON from '../tsconfig.json'; - -const cwd = `${__dirname}/..`; -// tslint:disable-next-line:no-floating-promises -postpublishUtils.runAsync(packageJSON, tsConfigJSON, cwd); diff --git a/packages/web3-wrapper/src/monorepo_scripts/stage_docs.ts b/packages/web3-wrapper/src/monorepo_scripts/stage_docs.ts deleted file mode 100644 index e732ac8eb..000000000 --- a/packages/web3-wrapper/src/monorepo_scripts/stage_docs.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { postpublishUtils } from '@0xproject/monorepo-scripts'; - -import * as packageJSON from '../package.json'; -import * as tsConfigJSON from '../tsconfig.json'; - -const cwd = `${__dirname}/..`; -// tslint:disable-next-line:no-floating-promises -postpublishUtils.publishDocsToStagingAsync(packageJSON, tsConfigJSON, cwd); diff --git a/packages/web3-wrapper/src/web3_wrapper.ts b/packages/web3-wrapper/src/web3_wrapper.ts index dd35e2094..ea78f8801 100644 --- a/packages/web3-wrapper/src/web3_wrapper.ts +++ b/packages/web3-wrapper/src/web3_wrapper.ts @@ -237,6 +237,7 @@ export class Web3Wrapper { /** * Retrieves an accounts Ether balance in wei * @param owner Account whose balance you wish to check + * @param defaultBlock The block depth at which to fetch the balance (default=latest) * @returns Balance in wei */ public async getBalanceInWeiAsync(owner: string, defaultBlock?: BlockParam): Promise<BigNumber> { |