Module types for ol/geom

This commit is contained in:
Tim Schaub
2018-03-11 23:08:50 -06:00
parent 41d9a84a8f
commit ef70d71636
60 changed files with 482 additions and 482 deletions
+1 -1
View File
@@ -3,7 +3,7 @@
* `readFeatures` returning an `Array.<ol.Feature>`
* `readFeature` returning an `ol.Feature`
* `readGeometry` returning an `ol.geom.Geometry`
* `readGeometry` returning an `module:ol/geom/Geometry~Geometry`
Having different functions for multiple return types allows both the user to specify what type of data they want and for the compiler to properly type check the code. Depending on the format, it is entirely reasonable to leave one or more of these methods unimplemented, or provide sensible default implementations.