Experiments >

Code animation: D3 variable tick spacing

Experiment #12613th April, 2021by Joshua Nussbaum

Following up on the experiment with infinite tick marks, I want to add scaling.

It occurred to me that D3 has libraries for this, so in this experiement I look into using D3 to scale and draw the tick marks.

It’s my first time using D3, so It took a lot of reading example code to figure it out, but it’s a pretty impressive library.

Code

https://svelte.dev/repl/99b98f430c21422a80c6efa886c290ce?version=3.37.0

Demo

Notes

  • There should be two types of tick marks, some with labels and some without.
view all experiments

Stay tuned in

Learn how to add more experimentation to your workflow