【发布时间】:2021-07-29 18:32:21
【问题描述】:
在 Meteor 中有一个类型:
interface User {
_id: string;
username?: string | undefined;
emails?: UserEmail[] | undefined;
createdAt?: Date | undefined;
profile?: any;
services?: any;
}
那么如何让 IntelliSense 将 User.profile 识别为我的类型 MyProfile?
【问题讨论】:
-
为什么不将配置文件定义为
profile?: MyProfile而不是profile?: any? -
这是 Meteor 的代码,不是我的。
标签: javascript jsdoc