Module: Bashly::Renderable

Included in:
Models::Base
Defined in:
lib/bashly/concerns/renderable.rb

Instance Method Summary collapse

Instance Method Details

#render(view) ⇒ Object



5
6
7
8
# File 'lib/bashly/concerns/renderable.rb', line 5

def render(view)
  template = File.read view_path(view)
  ERB.new(template, nil, '%-').result(binding)
end

#stringsObject



10
11
12
# File 'lib/bashly/concerns/renderable.rb', line 10

def strings
  @strings ||= MessageStrings.new
end