You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is only partly supported ATM, because of (at least) two issues I bumped into while stepping through the evaluation code path in one of the workers:
The expression assigned to fill-color above is considered feature constant, and so feature data is not loaded during evaluation. This can be hacked around by wrapping the whole thing into e.g. a let with a get – but this is suboptimal (think ["let", "_" ["get", "room-type"], ["config", "room-color"]]).
Evaluating a match expression in the worker fails and defaults to the "otherwise" branch, if the expression being evaluated is a config expression. This happens here as the typeOf(input) === this.inputType check returns false, probably because the type constants in the worker are not referentially the same as the {kind: ...} value from the unserialized version of the config expression from the main thread(?).
I'd like to have
config
properties that are expressions. I'd also like those expressions to be able to use feature properties, like so:This is only partly supported ATM, because of (at least) two issues I bumped into while stepping through the evaluation code path in one of the workers:
The expression assigned to
fill-color
above is considered feature constant, and so feature data is not loaded during evaluation. This can be hacked around by wrapping the whole thing into e.g. alet
with aget
– but this is suboptimal (think["let", "_" ["get", "room-type"], ["config", "room-color"]]
).Evaluating a
match
expression in the worker fails and defaults to the "otherwise" branch, if the expression being evaluated is a config expression. This happens here as thetypeOf(input) === this.inputType
check returnsfalse
, probably because the type constants in the worker are not referentially the same as the{kind: ...}
value from the unserialized version of the config expression from the main thread(?).mapbox-gl-js version: 3.11.0
browser: Arc
Link to Demonstration
https://codesandbox.io/p/sandbox/lxfnlg?file=%2Findex.html%3A39%2C20
(If both of these issues are fixed, one of the squares should be red.)
The text was updated successfully, but these errors were encountered: