rungwiroon / BlazorGoogleMaps

Blazor interop for GoogleMap library
MIT License
325 stars 105 forks source link

No RectangleList? (Cannot add previously saved Rectangle to map) #311

Closed GCoding83 closed 8 months ago

GCoding83 commented 8 months ago

I have rectangles and polygons saved in my database. After the map is initialized, I am able to display the polygons by calling the await PolygonList.CreateAsync() method, which takes my PolygonOptions dictionary as a parameter. However, there is no equivalent to PolygonList for rectangles, and I don't know why. If I try calling await Rectangle.CreateAsync(), which takes RectangleOptions as a param, nothing gets displayed on the map. The method returns a Rectangle object, but I don't know if I'm supposed to do anything with it.

Am I doing something wrong? Shouldn't the call to await Rectangle.CreateAsync() suffice to display the Rectangle?

Thanks.