JSFiddle - React, Tailwind, and code Playground

by brigand

JavaScript

let ref = useState(() => new MyClass('test'));
    
    const onClsClick = (e) => {
    //some on click code, related to the CLS class
    //need to use cls here on this event
    }
    
    useEffect(() => {
        cls.start();
    }, []);