D3.js Choropleth Map Help Needed

Here is my latest code for this.

I have two main issues right now.

  1. The legend colors aren’t showing up.
  2. What type is the values variable passed in to then for Promises.all supposed to be?

Locally, I have this error:

error TS2339: Property 'features' does not exist on type 'Feature<Point, { [name: string]: any; }>'

on this line of code:

.data(topojson.feature(us, us.objects.counties).features)

in here

.then((values:any[]) => {
    const [eduation, us] = values;
    svg.append("g")
      .attr("class", "counties")
      .selectAll("path")
      .data(topojson.feature(us, us.objects.counties).features)
  });

There’s also this error in the console:

d3.v6.min.js:2 Error: <g> attribute transform: Expected ')', "…ranslate(60, 60 + 40)".

I don’t understand that one at all. Why is it saying, “Expected ‘)’” when a closing parenthesis is already there?

Any help is appreciated. Thanks.