Microsoft/TypeScript

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

Open

#62,396 建立於 2025年9月4日

在 GitHub 查看
 (1 留言) (0 反應) (0 負責人)TypeScript (6,726 fork)batch import
BugDomain: Error MessagesHelp Wanted

倉庫指標

Star
 (48,455 star)
PR 合併指標
 (平均合併 2天 7小時) (30 天內合併 8 個 PR)

描述

🔎 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

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

貢獻者指南