Thursday, December 10, 2020

[(ngModel)] doesn't work with "no value accessor for form control with name:.."

 I kept getting "no value accessor for form control with name:.." when using [(ngModel)]. I checked everything and followed exact the same code in those user guide, but I still couldn't get around this error. Finally, I found the following discussion. I added ngDefaultControl to the input and solved my issue!

https://stackoverflow.com/questions/46465891/what-is-ngdefaultcontrol-in-angular/46465959



No comments:

Post a Comment