Calling a method on a function definition in coffeescript

前端 未结 4 399
清酒与你
清酒与你 2021-01-17 16:05

How would you translate this snippet of javascript to coffeescript? Specifically I\'m struggling with how to call .property() on the function definition.

4条回答
  •  清歌不尽
    2021-01-17 16:59

    Something like this will work?

     (() => this.get("firstName") * this.get("lastName")).property()
    

提交回复
热议问题