Module: RevealCK::Render::PluginFiles

Included in:
Scope
Defined in:
lib/reveal-ck/render/plugin_files.rb

Overview

Determine which js files are in the plugin dir

Instance Method Summary collapse

Instance Method Details

#plugin_filesObject



5
6
7
8
9
10
11
12
# File 'lib/reveal-ck/render/plugin_files.rb', line 5

def plugin_files
  things_in_plugin_dir = FileList["#{@dir}/plugin/**/*"]
  only_js_files = things_in_plugin_dir.grep(/\.js$/)
  relative_plugin_files = only_js_files.map do |file|
    file.sub("#{@dir}/", '')
  end
  relative_plugin_files
end