Creating a component directly using ViewContainerRef.createComponent or using a component directly in a template without any parameters will result in the error
eric-gitta-moore opened this issue · comments
Describe the bug
Creating a component directly using ViewContainerRef.createComponent or using a component directly in a template without any parameters will result in the error
To Reproduce
// ...
ngAfterViewInit(): void {
setTimeout(() => {
const ref = this.container.createComponent(BarVerticalComponent);
ref.instance.view = [700, 300];
ref.instance.results = this.data;
});
}
// ...
or
<!-- But if you add any of the input attributes, you won't have a problem -->
<ngx-charts-bar-vertical></ngx-charts-bar-vertical>
Expected behavior
A clear and concise description of what you expected to happen.
Demo
https://stackblitz.com/edit/vertical-bar-chart-i1i4qy?file=app%2Fapp.component.html
https://vertical-bar-chart-i1i4qy.stackblitz.io/
ngx-charts version
20.5.0