This repository has been archived on 2021-09-06. You can view files and clone it, but cannot push or open issues or pull requests.
vuejs_course/2021-01-18 basics-assignmen.../index.html

30 lines
1.0 KiB
HTML
Raw Permalink Normal View History

2021-01-18 21:53:52 +01:00
<!DOCTYPE html>
<html lang="en">
2021-01-18 21:54:10 +01:00
<head>
2021-01-18 21:53:52 +01:00
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Vue Basics</title>
2021-01-18 21:54:10 +01:00
<link href="https://fonts.googleapis.com/css2?family=Jost:wght@400;700&display=swap" rel="stylesheet" />
2021-01-18 21:53:52 +01:00
<link rel="stylesheet" href="styles.css" />
<script src="https://unpkg.com/vue@next" defer></script>
<script src="app.js" defer></script>
2021-01-18 21:54:10 +01:00
</head>
<body>
2021-01-18 21:53:52 +01:00
<header>
2021-01-18 21:54:10 +01:00
<h1>Reactivity in Action</h1>
2021-01-18 21:53:52 +01:00
</header>
<section id="assignment">
2021-01-18 22:12:11 +01:00
<button @click="increaseCounter(5)">Add 5</button>
<button @click="increaseCounter(1)">Add 1</button>
2021-01-18 21:54:10 +01:00
<!-- 1) Connect the buttons and calculate a value (a number) -->
<!-- Show "Not there yet" until you reach a result of exactly 37 -->
<!-- Show "Too much!" if the result is greater than 37 -->
2021-01-18 22:26:19 +01:00
<p>Result: {{ status }}</p>
2021-01-18 21:54:10 +01:00
<!-- 2) Watch for changes in "result" and reset the value to 0 after 5 seconds -->
2021-01-18 21:53:52 +01:00
</section>
2021-01-18 21:54:10 +01:00
</body>
2021-01-18 21:53:52 +01:00
</html>