First of all big kudos out for this great piece of software! I don't know what I would do without it.
Now considering the recent growth of TypeScript usage across the JS / node eco system and the revival of static typing in general:
Would you consider a PR that merges the definitely-typed TS declarations into the main repo?
npm install instead of twoLet me know what you think :)
Happy holidays!
@andywer In the meantime, if proper use of TypeScript is a priority in your project, consider [pg-promise], which ships with embedded [TypeScript] support.
To point out a precedent: knex.js did exactly that for 0.16.x version. It doesn't mean that same necessarily makes sense for node-postgres as well, but it might :)
+1 to adding type definitions into the main repo. A lot more pleasant when there's updates across major versions to have the types updated in tandem.
There aren't many public API changes to pg (yes it's __that__ awesome!) so I doubt it'd be much of a maintenance burden but I'd be happy to contribute to keeping things in sync and reviewing any potential changes.
You may find this helpful:
https://github.com/sindresorhus/typescript-definition-style-guide
I was specifically interested in the testing recommendations:
https://github.com/sindresorhus/typescript-definition-style-guide#testing
Maintaining types is usually doable for a maintainer that doesn't use types day to day. But I do think having some form of testing consideration should be mandatory for including types in repos. Separate types have no implied guarantee of fitness for every version but I would be uncomfortable including source code in the repo that's untested.
typescript +1
Most helpful comment
typescript +1