This commit is contained in:
@@ -687,6 +687,7 @@ Projektarbeit
|
||||
|
||||
- Debugging-Techniken – Chrome Debugger
|
||||
- Webentwickler Developer Tools
|
||||
- Einrichtung von Eslint und AirBnB-Richtlinien
|
||||
- Debugging-Techniken – VSCode Debugger
|
||||
|
||||
**Übungen:**
|
||||
|
||||
@@ -36,12 +36,7 @@
|
||||
const init = () => {
|
||||
const areas = calcRectangles(rectangles);
|
||||
|
||||
let html = '';
|
||||
areas.forEach((area, idx) => {
|
||||
html += `Area of Rectange ${idx + 1}: ${area}<br />`;
|
||||
});
|
||||
|
||||
DOM.output.innerHTML = html;
|
||||
outputAreaResults(areas);
|
||||
};
|
||||
|
||||
// === EVENTHANDLER =====
|
||||
@@ -57,6 +52,15 @@
|
||||
return areas;
|
||||
};
|
||||
|
||||
const outputAreaResults = (areas) => {
|
||||
let html = '';
|
||||
areas.forEach((area, idx) => {
|
||||
html += `Area of Rectange ${idx + 1}: ${area}<br />`;
|
||||
});
|
||||
|
||||
DOM.output.innerHTML = html;
|
||||
};
|
||||
|
||||
init();
|
||||
})();
|
||||
</script>
|
||||
|
||||
@@ -19,6 +19,8 @@
|
||||
{
|
||||
NodeList.prototype.__proto__ = Array.prototype;
|
||||
|
||||
console.log(document.querySelectorAll('div').filter((el) => el.classList.contains('container')));
|
||||
|
||||
const Math = 123;
|
||||
// console.log(Math.sin()); // TypeError: Math.sin is not a function
|
||||
// console.log(Math.PI); // undefined
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
const myCar = { name: 'Toyota', model: 'Camry' };
|
||||
|
||||
/* greet(42); // => TypeError: Argument of type 'number' is not assignable to parameter of type 'string' */
|
||||
// reet(42); // => TypeError: Argument of type 'number' is not assignable to parameter of type 'string'
|
||||
|
||||
greet('11');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user