[기본문법 14] CSS in JavaScript part Two
Click me! body { background-color: beige; } h1 { color: cornflowerblue; transition:color .5s ease-in-out; } .active { color: tomato; } .sexy-font{ font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; } // event const h1 = document.querySelector("div.hello:first-child h1"); function handleTitleClick()..
2023. 2. 14.
[기본문법 6] return
// returns const calculator = { plus: function (a, b) { return (a + b); }, minus: function (a, b) { return (a - b); }, times: function (a, b) { return (a * b); }, divide: function (a, b) { return (a / b); }, power: function (a, b) { return (a ** b); }, }; const plusResult = calculator.plus(2, 3); console.log(plusResult); // Returns const age = 96; function calculateKrAge(ageOfForeigner) { retur..
2023. 2. 9.