Boost your d3.js learning kickoff

Iāve been involved in teaching d3.js and data visualisation in several classes since more than five years.
Every time itās like the first time.
Itās always a challenge because every class is diverse and every student is unique. Itās an ever learning process that is rewarding for this reason.
Since the coming of the 6th edition of Bigdive, Iāve started to think about how to improve the learning experience of the dataviz track Iām going to provide in class. Itās something I try to do every year.
Iāve already penned some words related to some updates that are in the pipeline.
This time Iām going to focus on something more fundamental.
In any disciplines the hardest part is the beginning, the kick-off, the phase related to understand the basics.
Out of my teaching experience, Iāve started to see patterns related to the difficulties the students usually face with.
Itās like there was a missing step between the zero knowledge and the first line of code.
Indeed, itās the lack of the DOM understanding.
D3.js is a layer on top of the DOM technology. You cannot really understand the library without a good understanding of its foundations.
The DOM looks like a toy for experienced programmers and maybe this is the reason why itās common to find d3.js tutorials that take the DOM for granted. It shouldnāt be like that.
What Iāve seen in my experience is that the more the students have an understanding of HTML/SVG and CSS selection the faster is the route to be proficient with d3.js.
This is why I do usually teach the basics of DOM during the first lesson.
Having said that, the best advice I can give to people wishing to learn d3.js is pretty straight:
Learn the DOM first.
That means, start learning the foundation of the web platform and its technologies such as:
- How the HTML works
- How the SVG tag works, the primitive elements, the coordinate system, the scene graph
- How CSS selection works
Even with a brief understanding of the above topics, approaching the basic of D3.js become way easier by an order of magnitude.
Happy learning!