Sha256: 6ec9729b498ca1942db7d15f49e1e278a2028cb02bf6984a674892efce6dc490

Contents?: true

Size: 693 Bytes

Versions: 1

Compression:

Stored size: 693 Bytes

Contents

require 'ostruct'
require 'json'

module RevealCK
  # A Config represents core configuration options within
  # reveal-ck. It has defaults. It is mutable.
  class Config < OpenStruct
    def initialize
      super DEFAULTS
    end

    def merge!(hash)
      hash.each_pair do |name, value|
        modifiable[new_ostruct_member(name)] = value
      end
    end

    DEFAULTS = {
      'title'      => 'Slides',
      'author'     => '',
      'theme'      => 'default',
      'transition' => 'default',
      'revealjs_config' => {
        'controls' => true,
        'progress' => true,
        'history' => true,
        'center' => true
      },
      'data' => {

      }
    }
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
reveal-ck-0.3.0 lib/reveal-ck/config.rb