I'm trying to add a description to a legend. I figured out how to show the legend and how to add the description if it is a plain text. I'm stuck on how to pass the description to the legend. Could anyone help me?
I created a minimal example: https://codepen.io/nwp_nadja_bernhard/pen/yLEVdZz
The code in question starts at row 173;
in the function fetchAsync (row 177) I manage to address the desired text -> desc;
in the function create_legend (row 204) I manage to add a static text in the desired place "content" -> description - currently commented;
--> How can I pass the text into the legend content?