Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove generated Typescript definitions
When adding JSDoc to our functions our main points were 1. Give us documentation, API docs 2. Give autocomplete and type suggestions in supporting IDEs As an added bonus, we found that it was possible to generate TypeScript definition files directly from the JSDoc definitions. There were already community efforts at DefinitelyTyped for both sinon and its sub-projects, like fake-timers, but as external projects they suffered from being out-of-sync with the projects they were supposed to describe. Our thoughs were then that by generating these directly from the source that we could in time catch up with the DT efforts and be the main source of up-to-date .d.ts files. Unfortunately, there were some aspects of our types that were hard to describe statically using JSDoc, such as those where TypeScript would utilize its typeof type operator. That resulted in contributions that used the fact that TSC ignored invalid type definitions to describe types using those TypeScript features. The result was valid d.ts files, but invalid JSDoc, meaning our two main points were unmet. JSDoc simply is not powerful enough to generate the types expected by the users of the DefinitelyTyped types. So, in order to get back to what we mainly want, we stop shipping TypeScript definitions and continue to let this be a community maintained effort at DT (as it was). This should result in less friction (as experienced in the last few months), but will, of course, have the downside of always lagging a bit behind.
- Loading branch information