Is there a way to make the labels in a legend with horizontal direction wrap?
I made a simple example wtih the cars dataset where i transformed the categtories to generate longer strings in the Vega Editor:
Suppose I have more categories but also want to put the legend at the top/bottom to provide more horizontal space for the chart area.
Use the columns
property of legend
:
{
"legend": {
"orient": "top",
"direction": "horizontal",
"columns": 2
}