AngularDart 中旧地图/@attr 的等效注释是什么? [英] What is the equivalent annotation for the old map/@attr in AngularDart?
问题描述
AngularDart 教程(来自在撰写本文时),建议将组件字段绑定到这样的属性:
map: const {'最大评级' : '@maxRating','评级':'<=>评级'}
然而,我也看到 Angular 有 @NgOneWay
、@NgTwoWay
等.我找不到 @
的注释.如果我想要与 @maxRating
相同的语义,我想要哪个注释?
显然:
@NgOneWay
== =>
@NgTwoWay
== <=>
@NgOneWayOneTime
== =>!
???
== @
我认为 @NgAttr
就是你要找的.p>
对于回调,还有 @NgCallback
== &
- 只是为了完成你的列表.
The AngularDart tutorial (at of the time of this writing), recommends binding component fields to attributes like this:
map: const {
'max-rating' : '@maxRating',
'rating' : '<=>rating'
}
However, I see also that Angular has @NgOneWay
, @NgTwoWay
, and others. I can't find the annotation for @
. Which annotation do I want if I want the same semantics as @maxRating
?
Apparently:
@NgOneWay
== =>
@NgTwoWay
== <=>
@NgOneWayOneTime
== =>!
???
== @
I think @NgAttr
is what you are looking for.
For callbacks there is also @NgCallback
== &
- just to complete your list.
这篇关于AngularDart 中旧地图/@attr 的等效注释是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!