Closed martindholmes closed 3 years ago
The error we see when trying to draw the rectangle is this.sketchFeature_ is null
.
Interestingly, this error does not occur when using ol-debug.js, only when using ol.js. This suggests either a bug in the OL build process, or some sort of failure to surface a required method at compile time.
Fixed. I just needed to switch from using a custom drawing function to using the built-in ol.interaction.Draw.createBox() function.
Just doesn't work properly -- try it in the test sites. It was probably never fully implemented.