class Kitchen::Directions::BookAnswerKeyContainer::V1
Public Instance Methods
bake(book:, solutions_plural: true)
click to toggle source
# File lib/kitchen/directions/book_answer_key_container/v1.rb, line 7 def bake(book:, solutions_plural: true) @metadata = book.metadata.children_to_keep.copy @solutions_or_solution = solutions_plural ? 'solutions' : 'solution' book.body.append(child: render(file: 'eob_answer_key_outer_container.xhtml.erb')) book.body.first("div.os-eob.os-#{@solutions_or_solution}-container") end