Untitled
✓ Published0🌍 Public
This example demonstrates how to load data from a local ES6 module and update the text content of an HTML element. The code imports a parsed JSON array of car objects from `cars.js`, selects the first car’s make, and assigns it to the `textContent` of an element with the ID `message-element`. It uses D3 via UNPKG for module loading, alongside standard DOM manipulation through `document.getElementById`. The page renders a large, styled message in a `<pre>` tag.
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.
MIT Licensed