Error: Template parse errors: No provider for NgSwitchSan6yAsked Nov 8, 2019, 5:55 AM3.1kAngularWhy am I getting this error,even I try to include NgSwitch directive Error: Template parse errors:No provider for NgSwitch ("
Sanjit Kumar Singh6y agoPosted Nov 8, 2019, 11:45 AMAccepted answerHi Sandeep, If you have not imported the CommonModule then please import it from '@angular/common'. Key points ngSwitch can't be on a element, only on real elements like Only ngSwitchCase can be applied to elements Alternatively since final ng-container can be used instead of with the more common syntax: I hope that it will solve your problem.
Sanjit Kumar SinghPosted Nov 8, 2019, 11:45 AM