The Delightful World of Vue
v-on & methods: User Interaction
  Start your All-Access Pass to unlock this challenge
Buy Access Login

Challenge 1 / 3

Let's imagine we have these two boolean variables: collapsed and darkMode and we want to change the width and color of an element based on the state of these. What is the correct way to accomplish this using a style attribute?

Skip challenges and go to theNext Chapter

Turn Challenges Off?

All further challenges will be skipped automatically.
You can re-enable challenges at any time on this page or from your account page.