Hi,
I'm actually coding an app that needs specific polygons (self-intersection is forbbiden) for area selection (extraction of geometries for cell-broadcasting) and a features selection. I know we can simplify geometries but for this app i need to show a different style of polygon you can't finish with a double-click, i need to disable the draw-end event on the double click if the polygon is self intersecting. So my question is : Can i find the draw.js source code (not minified) on the web ?
I saw a demo of this at the Dev Summit this year.
Look here:
GitHub - ekenes/esri-js-samples: Some select samples using the ArcGIS API for JavaScript
They were able to not allow a feature to be finished when it had self-intersecting lines.