keithwhor/nodal

Add TypeScript definition file.

charrondev opened this issue · 3 comments

I already have a definition file I've made myself, mostly covering migration, models, and controllers, but I could finish it and make a pull request if you would be willing to include it in the project. It's just a 1-liner in package.json pointing to the definition.

Not everyone uses typescript, but the extra information can really help autocomplete and discovery of the API even when just using javascript.

@charrondev can you share that declaration file with me (somehow)...and maybe leave a quick how-to instructions to add to the nodal project ?

Don't worry about finishing it, even some definitions would be better than none.

@nik-lus I submitted them to the official DefinitelyTyped repo a while ago. You can submit a pull request there if you want to edit them. I've also linked them here.

Alternatively, if you use Typescript 2.0+ you could just use npm install --save-dev @types/nodal