Hello Vizhub
✓ Published0🌍 Public
This example displays the text “Hello VizHub!” centered on the page using D3 v5’s `select` API to set the DOM element’s content. It demonstrates loading D3 from a CDN via UNPKG, importing the `select` function directly from the `d3` module, and importing a local ES6 module (`myMessage.js`) that exports the message string. The message is rendered inside a `div` with id `message`, styled by `styles.css`. The code shows modular JavaScript organization and straightforward D3 DOM manipulation without data binding or scales.
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