Is there a way to dynamically load a component multiple times and pass data based on certain values so that it will display with real-time information?
I came across an example at the following link:
In this example, there is a messageComponent with a "message" property. We add a template in the hostComponent's HTML file like this:
<div style="text-align:center">
<h1>
Welcome to {{ title }}!
</h1>
<template #messagecontainer>
</template>
</div>
Instead of the template tag, the messageComponent will be inserted.
I am looking for a solution where we can iterate this template multiple times and dynamically pass different values for the "message" property in the messageComponent.