JSFiddle - React, Tailwind, and code Playground
HTML
<style>
p {
counter-increment: myIndex;
}
p::before {
content: counter(myIndex) '. ';
}
</style>
<p>First make a variable (myIndex) and make it increase every time a p element occurs.</p>
<p>Then insert the counter in front of all p elements</p>