The @key directive is important when creating components dynamically by iterating list/IEnumerable. Adding the @key will ensure proper change detection and UI update in the collection of components.
Reference link: https://blazor-university.com/components/render-trees/optimising-using-key/
Share with