Menu
CoddyTech

Recap: Derived Views

Part of the Fundamentals section of Coddy's Vue journey. Lesson 15 of 55.

challenge icon

Challenge

Easy

Build a donation meter. Start with 2 pledges worth 5 each. Show the computed amount in p#result. Button #pledge adds one pledge. Give div#meter a bound width equal to the amount in pixels and a funded class when the amount is at least 20. Keep a permanent meter class.

Try it yourself

<!doctype html><html><head><meta charset="UTF-8"><title>Vue practice</title></head><body><div id="app"></div><script type="module" src="./main.js"></script></body></html>

All lessons in Fundamentals