Class: GuiDebugger::DebugPage
- Inherits:
-
Object
- Object
- GuiDebugger::DebugPage
- Defined in:
- lib/gui_debugger/debug_page.rb
Class Method Summary collapse
Class Method Details
.display ⇒ Object
11 12 13 14 15 16 |
# File 'lib/gui_debugger/debug_page.rb', line 11 def self.display text = File.read(template("main")) html = Erubis::Eruby.new(text).evaluate(context: GuiDebugger.debug_context) [200, { "Content-Type" => "text/html; charset=utf-8" }, [html]] end |
.template(template_name) ⇒ Object
7 8 9 |
# File 'lib/gui_debugger/debug_page.rb', line 7 def self.template(template_name) File.("../templates/#{template_name}.html.erb", __FILE__) end |