【发布时间】:2021-03-04 07:57:02
【问题描述】:
我是编程新手,如果问题很愚蠢,我很抱歉。 我正在使用Angular Emojis,我使用属性绑定显示带有变量的特定表情符号。
模板:
<angular-emojis [name]="emojivar" size="30" (mouseenter)="changeRoutine()" > </angular-emojis>
TypeScript 代码:
emojivar = 'taco';
changeRoutine(){
console.log(this.emojivar);
this.emojivar = 'tomato';
console.log(this.emojivar);
}
变量会改变,但表情符号不会改变。 有什么办法可以修复它,让它刷新吗?
【问题讨论】:
标签: angular typescript emoji property-binding