Checks if a coordinate is within a polygon.
I asked ChatGPT:
"please help me write a google chrome extension that takes as input:
1. list of coordinates on a map (latitude , longitude) that form a polygon
2. a single map coordinate
True: if the single coordinate is within the polygon
False: if the single coordinate is outside the polygon"
This is the result after couple of conversations and minor manual modifications.