Skip to content
Advertisement

JavaScript Button Toggle: Code Completion

Question is :

We provided some simple JavaScript template code. Your goal is to modify the application so that you can properly toggle the button to switch between an ON state and an OFF state. When the button is on and it is clicked, it turns off and the text within it changes from ON to OFF and vice versa. You are free to add classes and styles, but make sure you leave the element ID’s as they are.

JavaScript

so what i’ve tried

JavaScript

I am new to JavaScript that’s why i am here asking for help.

Advertisement

Answer

JavaScript
User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement