I have a subsection and I'm wondering how I can place html
divider between every subsection but not sure how to do that so I would be really appreciated if I can get any suggestion or help.
<div>
<a mat-list-item *ngFor="let subsection of section.subSections" (click)="navigateToSubsection(section.id,subsection.id)">{{subsection.sectionName}}
</a>
</div>
For example something like this:
You could use
<hr>
tag to render horizontal lines and*ngFor
directive'slast
local variable to avoid rendering the line after the last item.Try the following
Working example: Stackblitz