From c31f1b968609076e214c9214d942d9f980aa94c8 Mon Sep 17 00:00:00 2001 From: Kilokem Date: Fri, 20 Sep 2024 07:46:16 +0200 Subject: [PATCH] ForNow --- ConditionalConquest/index.html | 6 ++++++ ConditionalConquest/script.js | 7 +++++++ 2 files changed, 13 insertions(+) diff --git a/ConditionalConquest/index.html b/ConditionalConquest/index.html index 5c0dfe6..83c6f20 100644 --- a/ConditionalConquest/index.html +++ b/ConditionalConquest/index.html @@ -56,6 +56,12 @@

+ +
+

MethodChaining

+ + +
\ No newline at end of file diff --git a/ConditionalConquest/script.js b/ConditionalConquest/script.js index 055aeea..3c77a33 100644 --- a/ConditionalConquest/script.js +++ b/ConditionalConquest/script.js @@ -69,11 +69,18 @@ document.addEventListener("DOMContentLoaded", function() { out.innerHTML += "Replace letter 'a' with 'o': " + text.replaceAll("a", "o") + "
"; out.innerHTML += "Fill till 15 with 'o': " + text.padStart(15, "o") + "
"; out.innerHTML += "Fill till 15 with 'o': " + text.padEnd(15, "o") + "
"; + out.innerHTML += "Slice: " + text.slice(0, 3) + "
"; }else{ out.innerHTML = ""; } }; + document.getElementById("MethodChaining").onclick = function(){ + let name = window.prompt("Please enter your gorgeous name!!"); + username = username.strim() + } + + });