Angular Flex布局如何有条件地添加fxLayoutAlign

Muk*_*thi 4 angular-flex-layout angular6

这是我的代码

<div fxLayout="row"
     fxLayoutAlign="end center">
Run Code Online (Sandbox Code Playgroud)

我想给fxLayoutAlign添加一个条件。我不知道该怎么做。有人可以帮忙吗?

我尝试了以下方法:

<div fxLayout="row"
     fxLayoutAlign="isCondition? 'start center' : 'end center'">
Run Code Online (Sandbox Code Playgroud)

但没有任何作用

谢谢

Muk*_*thi 7

这对我有用。我在方括号中使用了 propertyBinding。