Block-a-Day #13. A quick demonstration of scaling a canvas for high-DPI (retina) displays.
What I Learned: I had forgotten that when setting width and height as styles with D3, you need to add the “px” or else it won’t take.
What I’d Do With More Time: I was considering creating an option to simulate the effect for non-high-DPI displays, but it wasn’t worth the effort, so if viewed on a 1x display, the same image will be shown on both sides.
Just what it sounds like. For fifteen days, I will make a D3.js v4 block every single day. Rules: