/** @deprecated */ support broken on mapped types
See original GitHub issueBug Report
🔎 Search Terms
vscode, jsdoc
🕗 Version & Regression Information
4.1.3
⏯ Playground Link
Playground link with relevant code
💻 Code
type ApiDict = {
/**
* jsdoc for getString
*/
getString: string;
/**
* jsdoc for getBoolean
*
* @deprecated
*/
getBoolean: boolean;
};
type Api = {
[key in keyof ApiDict]: {
(url: string): ApiDict[key];
};
};
declare const api: Api;
declare const api2: ApiDict;
api.getBoolean
api2.getBoolean

related issue
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:5 (1 by maintainers)
Top Results From Across the Web
Bundle.get() deprecated. How to fix this when converting to ...
Use the type-safe specific APIs depending on the type of the item to be retrieved, eg. getString(String). So how to solve this in...
Read more >Deprecated (Phased-out) Features and Supported Approach
Deprecated Field Rule80A (47) Value OrderC...
A Agency single order A
B Short exempt transaction (refer to A type) A
C Program Order, non‑index arb, for...
Read more >Deprecated Code: How Dependency Mapping Can Prevent ...
Deprecated code is a natural part of software's evolution. However, unaddressed deprecated code can lead to future code breaks and inefficient databases.
Read more >Prettier 2.4: new bracketSameLine option and TypeScript 4.4 ...
Deprecate the jsxBracketSameLine option in favour of the new bracketSameLine option that will work for HTML, Angular, Vue, and JSX. <!-- Input ...
Read more >Removal of mapping types | Elasticsearch Guide [8.5] | Elastic
Elasticsearch 8.0.0 no longer supports mapping types. For details on how to migrate your clusters away from mapping types, see the removal of...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Should this be expected to work then? In this contrived example,
PartialandMappedTypearen’t really assigning a new type to the properties, right?Either way, I find it confusing that a property can be marked as deprecated in a popup and not also include the strike-through. Why the inconsistency?
https://www.typescriptlang.org/play?#code/GYVwdgxgLglg9mABAcwKZQMJwDZwE4AUEO+AzgPwBciA3nqgCZWKlR4xjIA0i+Ahp1T0m1Vu04BfAJS1EiAFBz6UEHiQ1FcxAHoAVLsQABBqgAO9CHyiNEIUql54BaYYl3bNSxtWK48FADp+QWEuT0dnIW9EXzJyIKcQxjCtRAAjbBBUagByAPyczQl5YvkoAE9TBwBZPlMqhgAVStQAHkaAPkQAXlkAbQBpRA5EAGtUcrhgREaAXWpGwdmJAG55MpbELD8AJVRSUwR7HsQABT48WD5sVr2VNWaq1oqqqZR0bfwOjrWXh0+8HsDkdUAAmE61eqMR5tO6qMAw54tN5oTAkPDfX6bAFAw5gewAZhOcIeLSRr2mqIBP3WxHxUBi6NI1Bx+zxx16VPRBCkazprEZflIoJZ6NxIPBnI+3N58n5DNi-gJot2bJBRKlaL8PLW6202kQABEzBYrDYRodTCBTDwwHAWGwYOMoAALPBwEDIF1yo4M1y9RWBYTyfVGk2oSzWBjDJCW622+1iJ3oN0er0++mIYSSwVkUHxYRrUPG8wRs3Ri1wK02h3sZ2pz3e+VZxga3NKguMFZAA
Think as well that deprecated keys should inherit deprecation marks from their parents.
@deprecatedused to inform the user that this property will no longer exists in future versions. When this property removed, the type that used this deprecated key will also breaks so we should display this for the user as well.Right now the inconsistent status when the tooltip showing the
@deprecatedcomment on hover but don’t display the deprecation mark on the code feels buggy.