【发布时间】:2019-11-27 12:05:49
【问题描述】:
我需要 Angular 8 方面的帮助。我的代码现在是这样的:
this.starClicked.emit(' The rating ' + this.rating + ' was clicked');
但是我试了这样放还是不行:
this.starClicked.emit(' The rating ${this.rating} was clicked');
我的结果是完全相同的字符串:
The rating ${this.rating} was clicked。
我不知道我是如何让这个表达式插值起作用的!
【问题讨论】:
标签: javascript angular ecmascript-6