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

Typescript Typings #14

Closed
BrunnerLivio opened this issue Feb 23, 2017 · 5 comments · Fixed by #18
Closed

Typescript Typings #14

BrunnerLivio opened this issue Feb 23, 2017 · 5 comments · Fixed by #18

Comments

@BrunnerLivio
Copy link
Contributor

A nice-to-have would be some TypeScript Typings by contributing to the DefinitelyTyped repository. So you have nice support, when you're using TypeScript.

Are you planning to do this?

@micku7zu
Copy link
Owner

Really sorry, but I'm not really a TypeScript fan. I didn't use TypeScript and I don't plan to use it, so i'm not going to do that, but I don't have a problem if someone does that 😄

@BrunnerLivio
Copy link
Contributor Author

Alright, maybe I'll figure something out. Will let you know when I'm finished.

@BrunnerLivio
Copy link
Contributor Author

BrunnerLivio commented Mar 7, 2017

Pull request is online. Even if you don't know TypeScript, maybe have a look over index.d.ts file, if it is correct. I think you'll understand it more or less.

I added typings for methods on VanillaTilt class, which i considered as "public". Am I missing any?

static init(elements: HTMLElement | HTMLElement[], settings?: VanillaTilt.TiltOptions): void;
reset(): void;
getValues(): VanillaTilt.TiltValues;
destroy(): void;
addEventListeners(): void;
removeEventListener(): void;

@BrunnerLivio
Copy link
Contributor Author

BrunnerLivio commented Mar 8, 2017

I got merged!

Now you can install typings using npm install --save-dev @types/vanilla-tilt

Fancy Preview

I'll create a PR which updates the README.md

@micku7zu
Copy link
Owner

micku7zu commented Mar 8, 2017

Merged the request. Thanks! 👍

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 a pull request may close this issue.

2 participants