I use a lot Pluto.jl and PlutoUI.jl for teaching.
Now, I am trying to have a dynamic element in the title.
However, I am having trouble with the update of the TableOfContents
I have defined the function:
function answered(ans::String) if ans == "NR" md"""## 🔴 --- """ else md"""## 🟢 --- """ end end;
ans is the resulting object of:
@bind ans Radio(["a)","b)","c)","d)","e)","NR"], default = "NR")
This should give a sense of progress in the Table of Contents when answering a multiple-choice questionnaire.
Each question is preceded by a cell containing:
This prints the title perfectly well, according to the answer provided.
But the TableOfContents does not update unless I open “the eye” of a cell.
Any ideas for a workaround?