microsoft / microsoft/TypeScript

Deprecation error message reporting method type as deprecated instead of method name

未关闭
#62,396 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
Bug Domain: Error Messages Help Wanted
主要语言
Go
星标
111k
派生
14.3k
平均合并
2 天 4 小时
30 天内合并 PR
132

描述

### 🔎 Search Terms

deprecated type

### 🕗 Version & Regression Information

- This is the behavior in every version I tried, and I reviewed the FAQ for entries about _________

### ⏯ Playground Link

https://www.typescriptlang.org/play/?ts=5.9.2#code/JYWwDg9gTgLgBAbzgLzgXzgMyhEcBEyEAJvgNwBQFAxhAHYDO8MDtdmwA5gEoCGA7gGVqACwCmIXnAC8KAHQQARgCsx1GAAoEFOLri1wwADZioAeTAxg9BgC55vOgE8NASgppXcsLwZMROACunCJulEA

### 💻 Code

```ts
import { z } from "zod";

const tsconfigRawSchema = z.object({
compilerOptions: z.any()
}).passthrough();
```

### 🙁 Actual behavior

Hover passthrough:

```
'(): ZodObject<{ compilerOptions: ZodAny; }, $loose>' is deprecated.
```

### 🙂 Expected behavior

```
'passthrough()' is deprecated.
```

or something like that.

### Additional information about the issue

_No response_

贡献指南

打开贡献指南

调研方向

从链接的 TypeScript Playground 复现示例以及 issue 中展示的 `passthrough()` 调用开始,然后追踪其已弃用悬停文本的生成方式。完成的标准是悬停提示报告 `passthrough()`,而不是生成的方法类型,同时保留预期的弃用行为。

由索引模型根据 Issue 内容生成。

评估

技术栈
typescript
领域
compilers
Issue 类型
缺陷
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
45/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。