Skip to content

Commit acdc645

Browse files
Update main.js
1 parent 7d623a8 commit acdc645

File tree

1 file changed

+11
-1
lines changed
  • project-5-currency-converter

1 file changed

+11
-1
lines changed

project-5-currency-converter/main.js

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,14 @@ const worthSecondEl = document.getElementById("worth-second");
88

99
const exchangeRateEl = document.getElementById("exchange-rate");
1010

11-
// Continuing...
11+
function updateRate () {
12+
console.log("Option changed!");
13+
}
14+
15+
currencyFirstEl.addEventListener("change", updateRate)
16+
17+
currencySecondEl.addEventListener("change", updateRate)
18+
19+
worthFirstEl.addEventListener("input", updateRate)
20+
21+
// Continuing...

0 commit comments

Comments
 (0)