/challenge_1_toggle_button

Let's build a React Toggle Button!

Primary LanguageJavaScript

Challenge 1 - Let's Create A "Toggle" Button

Challenge Scope

This challenge will be occurring on June 27th, 9am - 2:30pm. If you're coming here after the fact, check out people's buttons at the bottom of this readme.

toggle button icon

This button should:

  • be a single button whose appearance changes on each click (appearance can mean color or w/e)
  • have 2 or more states
  • should cycle through the states and effectively loop

Fun ideas:

  • Have the button disable when it cycles 3 times through the states
  • Connect the button to an external image
  • Move the button on click
  • Add your own behavior!

Getting Started

There are 2 ways to get started:

Create your own React app and button! OR fork + clone this repository to your machine and work within /components/Toggle.js

NOTE: You might notice the Toggle.js is a class component, you are absolutely welcome to refactor this into a functional component using React hooks

We look forward to seeing what you come up with! If you're curious what folks came up with, see them below: