🌍 Public
Viewing a saved revision (read-only)
bec2a825cd1a41169a124ea484697d12
Car Report
This example demonstrates a simple text-based report of cars filtered by price, displaying each vehicle’s year, make, model, and cost. It shows asynchronous data loading with a Promise-based `getCars` function, ES6 module imports and exports, and string formatting via `formatCar`. The code uses `JSON.parse` to parse hardcoded car data and `textContent` to update the HTML `<pre>` element. It highlights modular JavaScript organization in VizHub without any charting or visualization libraries.
AI-generated descriptionAn example showing the capabilities of VizHub:
- Loads D3 via UNPKG.
- Demonstrates use of
importfrom"d3". - Demonstrates use of
importfrom local ES6 modules.