This commit is contained in:
2026-06-08 13:21:57 +02:00
parent 823130e3ac
commit 8bee76328b
23 changed files with 734 additions and 382 deletions
+35 -6
View File
@@ -1,9 +1,38 @@
let title = document.getElementById("title");
title.innerHTML = "Hello from js-maker";
title.addEventListener("click", function (evt) {
// exercise01
function replaceParagraphHtml(html) {
{
console.log("clicked");
return true;
const p3 = document.querySelector("p");
{
let p = p3;
p.innerHTML = html;
return p.innerHTML;
}
}
}
});
// exercise02
function addSourceLink() {
{
const p8 = document.querySelector("p");
{
let p = p8;
p.insertAdjacentHTML("afterend", "<a href=\"https://forcemipsum.com/\">Source</a>");
return true;
}
}
}
// exercise03
function paragraphText() {
{
const p15 = document.querySelector("p");
{
let p = p15;
return p.textContent;
}
}
}