Homework 2 #5

Merged
merged 7 commits into from Dec 12, 2018
File filter...
Filter file types
Jump to file or symbol
Failed to load files and symbols.
+1 −2
Diff settings

Always

Just for now

Fixed grabbing value from input field in temperature assignment.

  • Loading branch information...
norbs committed Nov 30, 2018
commit ab503e67af88e02f01d35b481d16b44f1da5d766
@@ -18,7 +18,7 @@ BONUS 3: Clear the contents of the text box after you've displayed your results,
*/

let getInput = function() {

This comment has been minimized.

@vodnik

vodnik Dec 12, 2018

Owner

I like your clean functional programming style -- everything function has a clear focus.

return document.querySelector('#temperature');
return document.querySelector('#temperature').value;
}

let fahrenheitToCelcius = function(fTemp) {
@@ -37,7 +37,6 @@ let convertCtFAndOutput = function() {
console.log(celciusToFahrenheit(getInput()));
}

//Couldn't quite get the eventListeners/input field to work
const ftcButton = document.querySelector('#fahrenheit_to_celsius');
const ctfButton = document.querySelector('#celsius_to_fahrenheit');
ftcButton.addEventListener("click", convertFtCAndOutput);
ProTip! Use n and p to navigate between commits in a pull request.