Validates the scale constraints of a style — scaleConfig (the layer) and labelScale
(its labels).
⚠️ Both are expressed in scale denominators (the X of 1:X), never in MapLibre zoom
levels. This is the point the retired zoomConfig got wrong: its name said zoom while the
engine read denominators, so { minZoom: 6 } hid layers at every zoom. zoomConfig is
therefore rejected outright rather than ignored, and unknown keys inside a scale object are
errors too — silently dropping them would leave the layer unconstrained, the same failure
one level quieter.
Both fields are optional; absent means no constraint. Accumulator contract — see
validateStyleRules.
Validates the scale constraints of a style —
scaleConfig(the layer) andlabelScale(its labels).⚠️ Both are expressed in scale denominators (the X of 1:X), never in MapLibre zoom levels. This is the point the retired
zoomConfiggot wrong: its name said zoom while the engine read denominators, so{ minZoom: 6 }hid layers at every zoom.zoomConfigis therefore rejected outright rather than ignored, and unknown keys inside a scale object are errors too — silently dropping them would leave the layer unconstrained, the same failure one level quieter.Both fields are optional; absent means no constraint. Accumulator contract — see validateStyleRules.