Angular 7 and can't bind to 'routerlink' since it isn't a known property of 'a'
The property routerLink
is case sensitive.
change [routerlink] to [routerLink]
[routerLink]="['/vendors']"
For those people who have routerLink
camel cased correctly and are still getting the same error, you probably have not imported RouterModule
inside the module that defines your component.
import {RouterModule} from '@angular/router';@NgModule({ declarations:[YourComponents], imports:[RouterModule]...
I had similar error "Can't bind to 'routerlink' since it isn't a known property of 'button' ".
Adding the module RouterTestingModule.withRoutes([]) to the spec class solved my issue.