Gradient Background Generator
This was my very first JavaScript project!
I have learnt how to create a background generator by using input elements and then using JavaScript to enable the page’s background to be changed based on the colours selected in the input elements.
I created for different variables using JavaScript – one for the h3 header, one each for the two different colours and the final one for the gradient.
Then I created a function that changed the background colour of the page based on the colours selected and then added two event listeners that would “listen” to the colours selected and change the background colours accordingly.
Finally, there’s a line of text at the bottom of the page that details what colours were selected.