5 lines
116 B
TypeScript
5 lines
116 B
TypeScript
|
const h1 = document.querySelector("h1")!;
|
||
|
h1.addEventListener("click", () => {
|
||
|
h1.classList.toggle("invert");
|
||
|
});
|