<p [ngStyle]="{backgroundColor: getColor()}"></p>. 其中backgroundColor也可以寫成background-color,getColor是在Angular內自己定義的function, ...
確定! 回上一頁