【发布时间】:2021-12-26 11:19:44
【问题描述】:
假设下面是一个泛型类型,我应该使用什么来代替 ??? 来正确记录 T?
/**
* ??? The description of T.
*/
class MyClass<T> {
}
在 C# 中,我会使用 <typeparam>。是否有官方等效的 JSDoc?
【问题讨论】:
-
@VLAZ 是的,我看到了,但不清楚它如何适用于我的案例。我应该写什么而不是上面的
???? -
老实说,我也不清楚。因此问号。我读过它,但我不确定它如何适用于 TS。
-
查看更多资源,您可能只需要
@template T - some description here参见here(它是TS 文档,但解释了如何注释JS 代码)和here is the full description of@template。烦人the JSDoc documentation doesn't mention@template -
@VLAZ 可以,谢谢。
标签: typescript jsdoc