0

I am creating dynamic components in the following way

<div #newComponents></div>

addCategory = (categoryName: string) => {
const formRowFactory = this.resolver.resolveComponentFactory(FormRowComponent);
const { instance: formRowComponent } = this.newComponents.createComponent(
  formRowFactory, // playing with the index over here
);
}

No matter what I use for the index in the createComponent call I always get the new component to be placed as first. What am I doing wrong?

0 Answers0