JSFiddle - React, Tailwind, and code Playground

HTML

<ul>
  <li id="t1">topic 1</li>
  <li id="t2">topic 2</li>
</ul>

JavaScript

$li = $( "li" ).get(1);
console.log (($li).value());