Layout and paint properties added after layer creation don't show up in queryRenderedFeatures results
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 12.4k
- Forks
- 2.4k
- PR merge metrics
- No merged PRs in 30d
Description
This was originally reported by @osvodef in https://github.com/mapbox/mapbox-gl-js/pull/10102
**mapbox-gl-js version**:
any
**browser**:
any
### Steps to Trigger Behavior
1. Create a map with a layer
2. Add a layout or paint property to the layer
3. Run `queryRenderedFeatures` and note that the dynamically added property is not in the results
### Link to Demonstration
https://jsfiddle.net/osvodef/f45dapvu/10/
### Expected Behavior
Dynamically added properties are shown in `queryRenderedFeatures` results.
### Actual Behavior
Dynamically added properties are not shown in `queryRenderedFeatures` results.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the queryRenderedFeatures entry point and reproduce the behavior using the linked JSFiddle. Trace how dynamically added layout and paint properties are handled after layer creation, then add coverage showing that those properties appear in queryRenderedFeatures results.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100