0

Using the mgt-person component in Angular with the parameter "user-id" not working with variables.

<ng-container *ngFor="let user of users">
  <mgt-person user-id="[[user]]" view="threeLines">
  </mgt-person>
</ng-container>
TemplateHelper.setBindingSyntax('[[', ']]');

have you any idea?

thanks

Haris Bouchlis
  • 2,366
  • 1
  • 20
  • 35
Mauro
  • 1

2 Answers2

0

Setting custom binding syntax works only inside <template> elements.

Here you're outside <template> so you have to use angular binding.

<mgt-person [user-id]="user" view="threeLines"></mgt-person>
Kamil Chlebek
  • 159
  • 1
  • 6
0

Like Kamil but with property name (and not attribute name)

<mgt-person [userId]="user" view="threeLines"></mgt-person>
Dadv
  • 324
  • 2
  • 17