'Set default font in vega lite

Can I set a font, e.g. in vega-lite's config object, that is used for all the labels and titles?

I currently set labelFont and titleFont for the x&y axis and the color legend, but it is the same font everywhere so it would be nice to set it just once.



Solution 1:[1]

Checkout config: fontConfig("monospace"). I'm on vega-lite 4.5.1 and it's there.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 hertopnerd