Show more than one line for answers to question_text() questions in learnr

Within a learnr tutorial, it is easy to ask a question which requires the student to type in some text as answer. By default, only one empty line is provided to the student. Here is an example:

question_text(
  "Student Name:",
  answer(NULL, correct = TRUE),
  allow_retry = TRUE,
  try_again_button = "Modify your answer",
  incorrect = "Ok"
)

Is there a way to display more than one empty line for the student to write in? I often ask my students to write a sentence or two of answers.

UPDATE: Thanks to a tip from Daniel Kaplan, I got this working. You can see the details here.

Fixed in https://github.com/rstudio/learnr/pull/460

1 Like

This topic was automatically closed 54 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.