ol.render.Feature does not have geometry.getFlatInteriorPoint
See original GitHub issueI got an Uncaught TypeError: geometry.getFlatInteriorPoint is not a function
unless I define format: new ol.format.MVT({featureClass: ol.Feature})
on ol.source.VectorTile
, which suggests that getFlatInteriorPoint
is not defined for ol.render.Feature
features.
Interestingly your example works just fine without featureClass: ol.Feature
.
I’ll investigate this issue further, just wanted to mention this at the first place - maybe you have a suggestion from the top of your head.
Issue Analytics
- State:
- Created 7 years ago
- Comments:10 (6 by maintainers)
Top Results From Across the Web
OpenLayers v7.2.2 API - Module: ol/render/Feature
Geometry name to use when creating the Feature. Returns: Newly constructed ol/Feature with properties, geometry, and id copied over.
Read more >Showing measurement in OpenLayers 6 while modifying
I have this code. I create class the name is MeasurementClass. this class used for overlays component creator, setting of html and configure ......
Read more >How can we render an OpenLayers 3 feature to a canvas ...
I have a sample which renders a geometry to a canvas honoring the ol3 style but it only runs with the unbuilt version...
Read more >OpenLayers 3 API Documentation - Class: Feature
You can set the geometry using the setGeometry method and get it with ... getGeometry(); // Render the feature as a point using...
Read more >ol-mapbox-style - UNPKG
The CDN for ol-mapbox-style. ... ","CLASS_CONTROL","CLASS_COLLAPSED","family","split","_obj_js__WEBPACK_IMPORTED_MODULE_5__","SimpleGeometry","Geometry" ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Note that in OpenLayers, you can always configure the MVT format with
featureClass: ol.Feature
to support that kind of thing.ahh, yes - that worked. thank you