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

typings #197

Closed
wants to merge 3 commits into from
Closed

typings #197

wants to merge 3 commits into from

Conversation

theluk
Copy link

@theluk theluk commented Apr 29, 2016

typings in the .d.ts format to enhance type safety and autocompletion for TypeScript based apps

Description

I added a annyang.d.ts file reflecting the public api.

TODO

I copied most of the comments, and enhanced them. Altough copying is a ugly solution, i did not find a common practice how to do it better.

Motivation and Context

I wanted to use annyang in a angular2 project.

How Has This Been Tested?

there are no tests right now, as I have no experience in how to test type definition. Any help would be nice. @typings

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@semagarcia
Copy link

Which is the state of that PR?

@jkuri
Copy link

jkuri commented Jan 21, 2017

any progress on this?

@hisham
Copy link

hisham commented Apr 20, 2017

+1 - this is needed.

@hisham
Copy link

hisham commented Aug 16, 2017

fyi I updated these typings and created a pull request in DefinitelyTyped project as maintainer of this project doesn't seem to be making this a priority. My pull request is at DefinitelyTyped/DefinitelyTyped#19031

@TalAter
Copy link
Owner

TalAter commented Aug 16, 2017

Hi @hisham,

If you'd like to send a pull request here as well I'll be happy to check it out. Hopefully, it can help a lot of our users.

Thank you.

@hisham
Copy link

hisham commented Aug 17, 2017

Thanks @TalAter, now that the annyang type definitions is in DefinitelyTyped, we don't really need to add it to annyang package, although it is preferred from DefinitelyTyped perspective, but no real impact on anyone.

Maybe I'll do it if I get some spare time here and there.

@theluk
Copy link
Author

theluk commented Aug 17, 2017 via email

@hisham
Copy link

hisham commented Aug 17, 2017

@theluk maybe you're referring to https://github.com/typings/typings? That's deprecated but as far as I see https://github.com/DefinitelyTyped/DefinitelyTyped is very much active and supported.

This is what they say in their documentation - I did the 2nd paragraph since this pull request didn't get merged and I needed the annyang type definitions.

Create a new package

If you are the library author, or can make a pull request to the library, bundle types instead of publishing to DefinitelyTyped.

If you are adding typings for an NPM package, create a directory with the same name. If the package you are adding typings for is not on NPM, make sure the name you choose for it does not conflict with the name of a package on NPM. (You can use npm info foo to check for the existence of the foo package.)

@theluk
Copy link
Author

theluk commented Aug 17, 2017 via email

@theluk
Copy link
Author

theluk commented Aug 17, 2017 via email

@TalAter
Copy link
Owner

TalAter commented Aug 20, 2017

I agree, @theluk.

I think it is best if we keep it within this package. This has several benefits:

  1. Users don't have to figure out where to get types from a separate dependency, and they don't have to add two dependencies.
  2. The types can be kept up to date and in sync with each of annyang's versions as the API changes.

@hisham hisham mentioned this pull request Aug 23, 2017
9 tasks
@hisham
Copy link

hisham commented Aug 23, 2017

Done - see #304.

@TalAter TalAter closed this Aug 23, 2017
@TalAter
Copy link
Owner

TalAter commented Aug 23, 2017

@theluk, @semagarcia, @jkuri
I would appreciate your advice on #304

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.

None yet

5 participants