I want to create components dynamically from an array. #cmp1, #cmp2, #cmp3 should be dynamic how can this be achieved
<my-component #cmp1></my-component>
<my-component #cmp2></my-component>
<my-component #cmp3></my-component>
componentList: string[] = ['cmp1', 'cmp2', 'cmp3']
And I have to fetch one these components dynamically at runtime based on a string value
let reqiuredComponent = 'cmp2'
let captureComponent: MyComponent = @ViewChild(requiredComponent)