Exception: ViewComponent::MissingPreviewTemplateError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/view_component/errors.rb

Constant Summary collapse

MESSAGE =
"A preview template for example EXAMPLE doesn't exist.\n\n" \
"To fix this issue, create a template for the example."

Instance Method Summary collapse

Constructor Details

#initialize(example) ⇒ MissingPreviewTemplateError

Returns a new instance of MissingPreviewTemplateError.



36
37
38
# File 'lib/view_component/errors.rb', line 36

def initialize(example)
  super(MESSAGE.gsub("EXAMPLE", example))
end