Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Cars Report

Public visualization

Viewing a saved revision (read-only)

5be0e50719d54dd1a8ca72dd0aa3acb9

Cars Report

0 stars0🌍 Public
PPaulCaballero
Last edited Aug 22, 2019
Created on Aug 22, 2019
Forked from Cars Report

This example demonstrates a simple text-based report of car listings, showing each car’s year, make, model, and price when priced under a given threshold. The page initially displays “Loading…” while a promise-based `getCars()` function simulates a two-second delay before resolving a hardcoded JSON array of five cars. The `generateReport()` function filters the array, maps each car through `formatCar()` to format the string, and joins them with newlines into a single report. No external libraries are used; the code relies on native JavaScript promises, array methods, and ES modules.

AI-generated description

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