JSFiddle - React, Tailwind, and code Playground
HTML
<style type="text/css">
p:nth-child(2){color:red;}
p:nth-of-type(2){border:1px solid #000;}
</style>
<div id="test">
<p>P One</p>
<p>P Two</p>
</div>
<div id="test">
<span>Span Test</span>
<p>P One</p>
<p>P Two</p>
</div>