InputLightweight
Static dataset
A data file shipped with the page.
A file of numbers shipped with the page (JSON or CSV) that places and colors everything. Nothing changes after loading, which makes it the easiest kind of data to work with. Big files delay the first paint.
- Breaks when
- large files block first paint
- Also called
- data viz, JSON, CSV
Prompts
Rows become a 3D field
Load /data/cities.json (2,400 rows: name, lat, lon, population) at build time (import it, no fetch) and place one InstancedMesh cylinder per row on a sphere by lat/lon, height by log(population), color by continent from a 6-color map. HTML labels for the top 12 by population, positioned with project() each frame only when the camera moved. State the file size and the time to first mesh.
Data-shaped typography
A CSV of 365 daily values drives a wall of 365 short bars laid out as a calendar (53 columns × 7 rows) in Canvas 2D; hovering a bar shows its date and value; the bars grow in on load in row order over 1.2 s. Parse the CSV with a 10-line function, no library, and validate the row count.
Split it so it loads
A 9 MB JSON dataset makes first paint slow. Convert it at build time to a binary Float32Array (.bin) with a small JSON index, load the index first, render the outline, then fetch the .bin and fill in. Show the loading order and the size after conversion.
Related
Resources
None yet. Find one and add it with npm run add -- <url>.