jsmreese / moment-duration-format

Format function plugin for the Moment Duration object.
MIT License
968 stars 120 forks source link

There is no typings file for this plugin. How to generate one? #73

Open bhaidar opened 7 years ago

bhaidar commented 7 years ago

Hello, I am using moment in my angular-cli project.

I want to make use of this plugin. However, there is no typings for it. How can I add typings so that I can use it?

Thanks

ekarious commented 6 years ago

I was looking for the exact same thing and if you still didn't fin one, you can find it here: https://www.npmjs.com/package/@types/moment-duration-format

lstanden commented 6 years ago

Reviving this one, as the typings are no longer valid with the 2.0.0 release as far as I can tell.

jsmreese commented 6 years ago

You're right -- that typings file is not longer valid.

I definitely want to get a typings file into the plugin. I'm focused on resolving some of the bugs and API issues from the 2.0 release right now. I can probably make time for a typings file in January, unless someone is able to make a PR with an updated typings file before then :)

lstanden commented 6 years ago

Have you considered converting your code to Typescript or Flow so you can publish the typings with each release? There's a lot to be said about writing library code in one of those.

saulshanabrook commented 6 years ago

It looks like those typings were updated to version 2.2.0 a month ago. However, I am having trouble getting them to work. Has anyone had luck with them?

ghost commented 6 years ago

Take a look at https://github.com/Microsoft/dts-gen to generate the new typings.