🌍 Public
Viewing a saved revision (read-only)
d69eeecf36114fc2ab68310de9fb4cdd
Fork of Cars Report
This example demonstrates a simple text-based data report, loading a hardcoded list of car objects and printing formatted lines for vehicles priced under $2,000. It shows the interaction between JavaScript modules, Promises, array methods, and template literals. The code uses `JSON.parse` to convert inline data, `setTimeout` inside a Promise to simulate a delayed API fetch, and `filter` with `map` to process the array before joining the results. The final output updates a `<pre>` element in the DOM through `document.getElementById` and `textContent`.
AI-generated descriptionAn example tutorial of how to use JavaScript objects, arrays, and modules.