Skip to main content
100%

Cars Report

✓ Published0🌍 Public
KKyleHincz
Last edited Aug 24, 2021
Created on Aug 24, 2021
Forked from Hello VizHub

This example generates a text-based report of cars priced under $2,000, displaying each car’s year, make, model, and price in a large-font `<pre>` element. It demonstrates ES6 module imports and asynchronous data loading, using `getCars()` to return a promise that resolves with a hardcoded JSON dataset after a two-second delay. The report is formatted by `formatCar` and generated with `generateReport`, which filters and maps the data, then joins lines with newline characters. The visualization relies on plain JavaScript, Promises, and DOM textContent manipulation, with no external libraries.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.
MIT Licensed

Similar vizzes