JSFiddle - React, Tailwind, and code Playground
HTML
<marquee>Click the button to get the tag name of the first element in the document that has a name attribute with the value "fname".</marquee>
<button onclick="start()">start</button>
<button onclick="stop()">stop</button>
JavaScript
start = function() {
document.getElementsByName("marquee")[0].start();
}
stop = function() {
document.getElementsByName("marquee")[0].stop();
}