Run ❯
Get your
own Node
server
❯
Run Code
Ctrl+Alt+R
Change Orientation
Ctrl+Alt+O
Change Theme
Ctrl+Alt+D
Go to Spaces
Ctrl+Alt+P
// @ts-check /** * Calculates the area of a rectangle * @param {number} width - The width of the rectangle * @param {number} height - The height of the rectangle * @returns {number} The calculated area */ function calculateArea(width, height) { return width * height; } // TypeScript knows the parameter and return types const area = calculateArea(10, 20); console.log(area);
Expected console output:
200