.nav-tab { // instead of putting it on border-right: 1px solid #424242; &:last-child { border-right: 0; // and then taking it off } // use CSS not() to only apply to the elements you want &:not(:last-child) { border-right: 1px solid #424242; } }

2 Responses

I use this a lot, but it's one of those things just not in my brain yet, and I find myself Googling it every time, ha! Now it's here. Thanks.
@Greg Smith :) You're welcome!

Write a comment
