Class: MarkdownTemplate

Inherits:
Tilt::Template
  • Object
show all
Defined in:
lib/gitdocs/markdown_template.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.engine_initialized?Boolean

Returns:

  • (Boolean)


13
14
15
# File 'lib/gitdocs/markdown_template.rb', line 13

def self.engine_initialized?
  true
end

Instance Method Details

#evaluate(scope, locals, &block) ⇒ Object



17
18
19
# File 'lib/gitdocs/markdown_template.rb', line 17

def evaluate(scope, locals, &block)
  @output ||= MarkdownConverter.convert(data)
end

#initialize_engineObject



6
7
8
# File 'lib/gitdocs/markdown_template.rb', line 6

def initialize_engine
  require_template_library 'pygments'
end

#prepareObject



10
11
# File 'lib/gitdocs/markdown_template.rb', line 10

def prepare
end