Open dcts opened 4 years ago
Thank you very much for this feedback.
Indeed, the gallery is currently all made for d3.v4... And I'm not sure what my plan is concerning the v5 since it would be a lot of work to migrate it all and many ppl still use the v4.
I'm considering adding a v4/v5 toggle button but I don't have time for it currently..
What do you think the best option is?
hey @holtzy , sorry for the late reply! My personal opinion is that its best to have everyone switch to the newest version, rather than providing multi version support for tutorials. I think if someone is using this tutorial page to learn d3.js, he or she should just use the newest version,since most of the time newer versions hold improvements. And if you have already a project in another version, its a good incentive to upgrade :)
But this is only valid if the newest version does not depricate functionality without replacing it. So if there is stuff you can do with v4 but not v5, this becomes a whole new discussion. But for that to decide i dont know enough about D3js.
I just noticed that the examples do not work with the newest d3.js release (v5). It took me forever to find out that this happens because the data loading with
d3.csv()
andd3.json()
now supports promise based syntax. So instead of writingYou can write
Thought i share it here maybe worth updating all the examples? If you want me to do it let me know, I could invest some time. Really thank you for providing this great page, really helpful.