-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow null as a filter value #4410
Comments
You can do this currently with |
Yes, see mapbox/mapbox-gl-style-spec#421. Main reason we haven't implemented it is in most cases you want |
But geojson does suuport null |
What would the semantics of |
@stevage I spent some time thinking about this while implementing mapbox/mapbox-gl-style-spec#451. My conclusion was that we should be as true to the Javascript semantics as possible. This would suggest that we should support |
Ah, thanks for pointing me to that. |
or please do not render it when property==null |
@zuo1188 I can top this! ;) To me this is an important feature for data-driven styling. Because you get GeoJSON data often from external data sources, and null is a valid value. I think an isNUll comparator would be handy. |
Closing this, as it will be covered by the upcoming 'arbitrary expressions' feature #4777 |
Correct me if I'm wrong, but after reading this, #421, and #4777, it appears that the intent in these discussions was to support a filter like |
I think |
mapbox-gl-js: 0.33.1
When I tried to filter out null values like this:
But it warns:
The text was updated successfully, but these errors were encountered: