D3 & SVG - Choropleth Map Project - State Borders Problem

Hey!

I just finished my Choropleth Project, it works, passes all the tests and I’d appreciate some feedback.

I just noticed I forgot to post the link…
Here’s the Codepen link - https://codepen.io/StaxXx/pen/LvpjLy

Additionally, I wanted to add state borders to the map and … mayhem!
Does anyone know what the problem is? Why doesn’t it work? I tried googling but have been unsuccessful.

You can remove the black areas by commenting out the last three lines (border) in JS.
Thank you in advance! :smiley:

The path elements that represent the states are filled black by default.

  1. add class states to your states so you could target them in your css file
  2. in css file select your states and remove the default black fill (fill: none)
  3. to make the state borders visible color them (stroke: red)

hope it helps :slight_smile:

2 Likes

Holy smokes, that makes sense, thanks for the explanation.

That worked perfectly.
Thanks a lot! :smiley:

1 Like