Menú

Final project

Can i please get a certificate.

here is my js code: 

const titleElem = document.querySelector(".title"); const title = titleElem.innerText; const chars = title.split("");
titleElem.innerText = "";
chars.forEach((char) => { const span = document.createElement("span"); span.innerText = char;
span.addEventListener("mouseover", () => { const rotate = Math.random() * 30 - 15; // -15..15 deg const scale = 1.4;
span.classList.remove("animate"); span.style.transform = "scale(1) rotate(0deg)";
// force reflow so animation can re-trigger void span.offsetWidth;
span.classList.add("animate"); span.style.transform = `scale(${scale}) rotate(${rotate}deg)`; });
span.addEventListener("mouseout", () => { span.style.transform = "scale(1) rotate(0deg)"; });
titleElem.appendChild(span); });   and HTML:   <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>Final Project</title>
<style> .title span { display: inline-block; transition: transform 0.2s ease, color 0.2s ease; cursor: pointer; }
.title span.animate { color: red; } </style>
<script src="script.js" defer></script> </head> <body> <h1 class="title">Final Project</h1> </body> </html>