Check out example codes for "More than one custom value accessor matches form control with unspecified name attribute". It will help you in understanding the concepts better.

Code Example 1

The problem here is: the ngx mask and angular material datepicker combined, they cannot be combined!
It is a limitation of Angular

<div class="form-group">
    <label class="control-label col-lg-2 text-right">Birthday</label>
    <div class="col-lg-4">
        <input type="text" class="form-control" formControlName="birthday" placeholder="MM/DD/YYYY"  mask="00/00/0000" autocomplete="off" bsDatepicker>
    </div>
</div>

Learn ReactJs, React Native from akashmittal.com