Relax typing for equality and order expressions #6459
Labels
api 📝
cross-platform 📺
Requires coordination with Mapbox GL Native (style specification, rendering tests, etc.)
#5840 relaxed the typing for
==
and!=
, making it possible to do:["==", ["get", "x"], 1]
without a type annotation for the"get"
expression.["==", ["get", "x"], null]
Some ways we could consider further relaxing typing for comparisons:
>
,<
, etc., allowing(number | string, value)
,(value, number | string)
so that[">", ["get", "x"], 5]
is valid.(value, value)
for equality and order expressions, so that . e.g.["==", ["get", "x"], ["get", "y"]]
is valid.The text was updated successfully, but these errors were encountered: