JSFiddle - React, Tailwind, and code Playground

HTML

<input type="checkbox" id="check">

JavaScript

document.getElementById('check').indeterminate = true;