Skip to content

How to draw COUNTY limits line #741

Answered by usefulthink
lukzfern asked this question in Q&A
Discussion options

You must be logged in to vote

That would be using the Data Driven Styling for boundaries.

There are some examples in the documentation that should get you started into the right direction, most of them can be translated into this library using useMap/useEffect like this (based on https://developers.google.com/maps/documentation/javascript/dds-boundaries/style-polygon#complete_example_code):

import { Map, useMap } from "@vis.gl/react-google-maps";
import { useEffect } from "react";

// Define a style with purple fill and border.
const featureStyleOptions: google.maps.FeatureStyleOptions = {
  strokeColor: "#810FCB",
  strokeOpacity: 1.0,
  strokeWeight: 3.0,
  fillColor: "#810FCB",
  fillOpacity: 0.5,
};

const CustomMap 

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@lukzfern
Comment options

@usefulthink
Comment options

@lukzfern
Comment options

Answer selected by lukzfern
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants