I'm currently working on a component with a multi-select dropdown feature. The goal is to be able to provide a list of objects (specifically ICatagory in my case) for the options when creating an instance of this component. Additionally, I want to pass another list of the same object type as preselected values.
As of now, I am successful in passing the list of objects and displaying them as options. I am also able to provide the preselected values. However, despite passing the preSelected values, they are not showing up as selected by default.
You can view the StackBlitz example here
This StackBlitz demo was created to provide clarity. Please note that upon loading, no items are selected. My intention is for the preselected values to automatically appear as selected upon creation.
I admit that I am still learning Angular, so there may be unconventional patterns present. Your understanding is appreciated.