question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Merge TypeScript declarations into repo

See original GitHub issue

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?

Background

  • It’s tricky to keep the typings package version and the actual package’s version in sync over
  • Not only for TypeScript users, but also for useful hints in the IDE
  • Coherence: Keep together what’s tightly coupled
  • Submitting a PR to that beast of definitely typed monorepo is a nightmare
  • One npm install instead of two

Let me know what you think 😃

Happy holidays!

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:26
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

16reactions
zuohuadongcommented, May 15, 2019

typescript +1

7reactions
bendruckercommented, Jan 8, 2019

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.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Documentation - Declaration Merging - TypeScript
For the purposes of this article, “declaration merging” means that the compiler merges two separate declarations declared with the same name into a...
Read more >
Declaration merging in TypeScript for regular devs - Merixstudio
In TypeScript, when two separate declarations with the same name are being merged into a single definition, it is called declaration merging. It ......
Read more >
TypeScript Tips Part II: Declaration Merging - Just Some Dev
Declaration merging has been around for a while now in TypeScript. In a nutshell it lets you merge definitions of types.
Read more >
Merge interface from namespace in module declaration file
I would like to extend the Document interface in a completely separate typescript library: https://github.com/CrossLead/tyranid-gracl which ...
Read more >
Type merging for imported types only works if the ... - GitHub
In typings_module: vars.d.ts: interface UserProperties { } declare global { const ... Typescript declarations tmedwards/sugarcube-2#45.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found