Last active
March 16, 2022 05:49
-
-
Save zahra-ove/b0da836a81574f973326ca49620fefa6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// create h1 element and append it to root element that already exists in the dom | |
const h = document.createElement("h1"); | |
h.textContent = "some dummy text"; | |
h.className = "header"; | |
document.getElementById("root").append(h); | |
======================= | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment