I'm encountering an issue with my data list in primeng as I try to run the app:
Can't bind to 'value' since it isn't a known property of 'p-dataList'
The HTML file looks like this:
<p-dataList [value]="cars">
<ng-template let-car pTemplate="item">
Car content
</ng-template>
</p-dataList>
Here is a snippet from my component file:
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
})
export class AppComponent {
title = 'app';
}
export class DataListDemo implements OnInit {
cars: Car[];
constructor(private carService: CarService) { }
ngOnInit() {
this.carService.getCarsLarge().then(cars => this.cars = cars);
}
}