How to bind to model with Angular Material ?

后端 未结 7 1707
花落未央
花落未央 2020-12-09 03:19

Take a look at this Plunker: https://plnkr.co/edit/yu95hUrKlUh4Ttc5SwYD?p=preview

When I\'m using , I am able to modify the valu

7条回答
  •  星月不相逢
    2020-12-09 04:00

    If you are trying to use mat-button-toggle to switch between enabling / disabling something, you will have to use a binding on mat-button-toggle-group, and make sure that the mat-button-toggle's themselves have the boolean values of true and false, not the string values. That is to say:

    
         Enable 
         Disable 
    
    

提交回复
热议问题