Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

first pass at a typescript declaration file #334

Merged
merged 1 commit into from
Jul 31, 2017
Merged

Conversation

rokob
Copy link
Contributor

@rokob rokob commented Jul 11, 2017

Addresses #302

@brianr
Copy link
Member

brianr commented Jul 11, 2017

Nice!

fyi @TimMensch that this is in progress

@TimMensch
Copy link

Thanks for the update and quick response. :)

@rokob
Copy link
Contributor Author

rokob commented Jul 31, 2017

I'm going to merge this so there is something and we can iterate on it further if there are any issues.

@rokob rokob merged commit 385b822 into master Jul 31, 2017
Copy link

@Agamnentzar Agamnentzar left a comment

Choose a reason for hiding this comment

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

Incorrect declarations of optional types

export = Rollbar;

declare class Rollbar {
constructor(options: Rollbar.Configuration?);
Copy link

@Agamnentzar Agamnentzar Jul 31, 2017

Choose a reason for hiding this comment

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

should be constructor(options?: Rollbar.Configuration);


public global(options: Rollbar.Configuration): Rollbar;
public configure(options: Rollbar.Configuration): Rollbar;
public lastError(): Error?;

Choose a reason for hiding this comment

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

should be public lastError(): Error | undefined;

captureUncaught?: boolean;
captureUnhandledRejections?: boolean;
}
export type Callback = (err: Error?, response: object) => void;

Choose a reason for hiding this comment

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

should be export type Callback = (err: Error | undefined, response: object) => void;

@rokob rokob deleted the typescript-declaration branch February 1, 2018 23:02
mudetroit pushed a commit that referenced this pull request Mar 14, 2024
first pass at a typescript declaration file
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