For work, I'm creating a Shiny App that allows the user to add information regarding a quiz question (a question, its possible answers, and an explanation) inside textInput
.
What I want to do is to insert a button ("Add new question") possibly with actionButton
that dynamically adds one additional question (= its group of textInput
for the question, its possible answers, and its explanation).
This is the group of textInput
s:
(Dummy example of a group of textInput
s):
textInput("question", label = h3("Question"), value = "Enter Question"),
br(),
br(),
textInput("correct_answer", label = h5("Correct Answer"), value = "Enter Correct Answer"),
textInput("wrong_answer", label = h5("Wrong Answer"), value = "Enter Wrong Answer"),
br(),
br(),
textInput("explanation", label = h3("Explanation"), value = "Enter Explanation"),
br(),
actionButton("add_new_question", "Add Another Quiz Question", class = "btn-primary"),
Please let me know if I should add in any other additional information!
Thanks,