Skip to content

bitcoinjs-lib fixed types, added re-exports#18932

Merged
mhegazy merged 3 commits intoDefinitelyTyped:masterfrom
dl3br:bitcoinjs-lib
Aug 14, 2017
Merged

bitcoinjs-lib fixed types, added re-exports#18932
mhegazy merged 3 commits intoDefinitelyTyped:masterfrom
dl3br:bitcoinjs-lib

Conversation

@dl3br
Copy link
Copy Markdown
Contributor

@dl3br dl3br commented Aug 14, 2017

Please fill in this template.

  • Use a meaningful title for the pull request. Include the name of the package modified.
  • Test the change in your own code. (Compile and run.)
  • Follow the advice from the readme.
  • Avoid common mistakes.
  • Run npm run lint package-name (or tsc if no tslint.json is present).

Select one of these and delete the others:

If adding a new definition:

  • The package does not provide its own types, and you can not add them.
  • If this is for an NPM package, match the name. If not, do not conflict with the name of an NPM package.
  • Create it with dts-gen --dt, not by basing it on an existing project.
  • tslint.json should be present, and tsconfig.json should have noImplicitAny, noImplicitThis, and strictNullChecks set to true.

If changing an existing definition:

  • Provide a URL to documentation or source code which provides context for the suggested changes: <>
  • Increase the version number in the header if appropriate.
  • If you are making substantial changes, consider adding a tslint.json containing { "extends": "dtslint/dt.json" }.

If removing a declaration:

  • If a package was never on DefinitelyTyped, you don't need to do anything. (If you wrote a package and provided types, you don't need to register it with us.)
  • Delete the package's directory.
  • Add it to notNeededPackages.json.

@dt-bot
Copy link
Copy Markdown
Member

dt-bot commented Aug 14, 2017

types/bitcoinjs-lib/index.d.ts

to authors (@mhegazy @rbuckton). Could you review this PR?
👍 or 👎?

Checklist

  • pass the Travis CI test?

@mhegazy mhegazy merged commit 279f799 into DefinitelyTyped:master Aug 14, 2017
addInput(hash: Buffer, index: number, sequence?: number, scriptSig?: Buffer): number;

addOutput(scriptPubKey: Buffer, value: number): number;
addOutput(scriptPubKey: Buffer | string, value: number): number;
Copy link
Copy Markdown

@dcousens dcousens Aug 15, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No optional string, Buffer only


export namespace address {
function fromBase58Check(address: string): { hash: Buffer, version: number };
function fromBase58Check(address: string): Buffer;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

output: {
check(script: Buffer): boolean;
decode(buffer: Buffer): Buffer;
encode(pubKeyHash: Buffer | number): Buffer;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

| number? nope

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants