Replies: 3 comments 6 replies
-
In angular using rxjs and NgRx I just create a new source with the updated feature list and do .setSource(newSource) on the layer. Works very well. |
Beta Was this translation helpful? Give feedback.
-
As a React + openlayers developer, that's my pattern as well. |
Beta Was this translation helpful? Give feedback.
-
On a second note: I just implemented it in my app, and it greatly improves integration with the Select interaction by keeping them selected even after editing features. Could be better for performance as well |
Beta Was this translation helpful? Give feedback.
-
I have to solve a small problem which goes as so. I am able to add layers to a map using this:
I have read that OpenLayers directly changes the DOM whereas React deals with the virtual DOM and this causes issues. Some of the layers I am working with depend on a date selection. I have a date component and when a user changes a date, the url for example changes. I have the map in a context so it is accessible by components. My idea is to have the calendar be part of the context so it accesses the map then when a date is selected, I do the following:
I have no tried this yet. Are there events on the map I can utilize?
Beta Was this translation helpful? Give feedback.
All reactions