Hello,
How do I display SQL Geography in ESRI JS?
My API returns a geography I inserted into SQL from a tutorial I found.
According to the API documentation (Polygon | API Reference | ArcGIS API for JavaScript 3.18 | Polygon | API Reference | ArcGIS API for JavaScript 4.1 ) there does not seem to be a way of constructing a polygon directly from the SQL WKT. Parse and plot - should be easy enough.
Check out GitHub - Esri/Terraformer: A geographic toolkit for dealing with geometry, geography, formats, and b... You'll need the WKT Parser module as well. A single AMD module with just the methods you need can be built with Browserify
Thanks everyone. I ended up writing a simple parser for the geometry and it looks like it's working.