JSFiddle - React, Tailwind, and code Playground

HTML

<a href="#">test</a>
<a href="#" class="active">test</a>
<a href="#">test</a>

CSS

a.active + a { color:blue }
a.active ~ a { color:red }