It's almost entirely unused. Instead we have two other approaches:
- Explicit import from core-provided modules (e.g. @import "mediawiki.ui/variables";).
- Implicit import from currently active skin or theme (not yet done, but under consideration for T112747).
Problems with $wgResourceLoaderLESSVars:
- Inherently lead to unmaintainable code. There is no explicit link between code stuffing variables in there (e.g. site configuration, extensions) and code consuming those variables. This makes it very fragile to change or migrate anything.
- Changing anything in there also results in immediate global invalidation of all Less-related caches because anything could be using it without knowing.
The last known use of it was to introduce a global variable deviceWidthTablet (T93675; 48263c3). Once that is moved to variables.less file and explicitly imported by callers, we can remove $wgResourceLoaderLESSVars from core.