VS Code中的角度智能感知未在html中显示对象属性

时间:2019-12-20 10:26:24

标签: angular typescript visual-studio-code intellisense

我已经安装了Angular Language Service,并且大多数情况下都可以正常工作,但是当我在""中编写角度代码时,即使我编写了{{ 1}}。对于"photo.",应该有 id,isMain 之类的内容,但它会再次显示照片,上传等。

如果我在照片中写了photo.这样不存在的内容,则会被删除,并显示错误“'照片'不包含该成员”,但是intellisense不会显示建议。

该如何解决?

照相课

photo.abc

组件:

export interface Photo {
    id: number;
    url: string;
    description: string;
    dateAdded: Date;
    isMain: boolean;
}

关于html中建议的问题:

enter image description here

0 个答案:

没有答案