Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Cars Report

Public visualization

Cars Report

0 stars0🌍 Public
Ttomaskrupa
Last edited Jul 19, 2020
Created on Jul 19, 2020
Forked from Cars Report

This example shows a JavaScript tutorial that filters a list of cars and formats them into a text report. The code parses a hardcoded JSON array using `JSON.parse`, applies `.filter()` to select cars priced under $2000, and uses `.map()` with a `formatCar` function to format each car’s year, make, model, and price. The resulting report is rendered as plain text into an HTML `<pre>` element via `document.getElementById('msg').textContent`. It demonstrates basic array methods, object destructuring, and template literals without external libraries.

AI-generated description

An example tutorial of how to use JavaScript objects, arrays, and modules.

Comments

Sign in to join the discussion.

MIT Licensed