Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

DOMCheckpoint2

In this project I created a button that onclick, makes another div change into different colors. I used HTML, CSS and JavaScript. In the JavaScript file, I used the DOMContentLoaded method to let the script run after the HTML has fully loaded. I used the getElementById method to select the elements that I want to work on. I generated a randomizer function that generates random rgb code colors that the id if color-box would change into on the click of the change-color-btn button. I added an eventListener to the change-color-btn element to trigger a function that tells the color-box element to change as soon as the button is clicked. Finally I added a box-shadow to the color-box element that changes color to the same color as the color-box.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages