HTML:
<h2 class="title-main">
<span class="title-inside">A</span>
<span class="title-inside">B</span>
<span class="title-inside">C</span>
<span class="title-inside">D</span>
<span class="title-inside">E</span>
<span class="title-outside">F</span>
<span class="title-outside">G</span>
</h2>
CSS:
:host/deep/.title-main {
display: flex;
margin-bottom: 0;
.title-inside {
&:after {
content : '-';
}
}
}
I am getting the output like this
A-B-C-D-E-F G
I don't want the - for the last child. I want the output like this
A-B-C-D-E F G
i tried many options. For eg. one of them which i tried
title-inside:last-child ::after {
content: ''
}
But this is not working. Could anyone please help me