完美的答案,只需将类型2修改为:[ngClass] =“ {'my-class':step =='step1'}”使用''int类名 ... 'conditional-class': this.item.id === 1 } return classes; }.
確定! 回上一頁