Sha256: d8a1901038fed935a8fd9f8c49ac5a40a9ada037dbf49a47df0e7c5a924fb204
Contents?: true
Size: 746 Bytes
Versions: 1
Compression:
Stored size: 746 Bytes
Contents
module RevealCK class SlidesHtmlBuilder def initialize(args) @input_file = args[:input_file] @presentation = args[:presentation] raise 'either :input_file or :presentation are required' unless @input_file || @presentation end def render if @input_file if @input_file.end_with? '.rb' presentation = RevealCK::Presentation.load @input_file presentation.content else template = TemplateProcessor.open @input_file template.output({}, {}) end else @presentation.content end end def write_to(args) file = args[:file] || raise(':file is required') File.open(file, 'w') { |f| f << render } end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
reveal-ck-0.1.5 | lib/reveal-ck/slides_html_builder.rb |