Class: Zfben_libjs::Coffee
- Defined in:
- lib/zfben_libjs/support_source/coffee.rb
Instance Attribute Summary
Attributes inherited from Source
#compiled, #filepath, #minified, #options, #source
Instance Method Summary collapse
Methods inherited from Source
#compile, #download!, #initialize, #minify, #name, #remote?, #type
Constructor Details
This class inherits a constructor from Zfben_libjs::Source
Instance Method Details
#before_compile ⇒ Object
6 7 8 |
# File 'lib/zfben_libjs/support_source/coffee.rb', line 6 def before_compile @compiled = CoffeeScript.compile(@source) end |
#before_minify ⇒ Object
10 11 12 |
# File 'lib/zfben_libjs/support_source/coffee.rb', line 10 def before_minify @minified = Zfben_libjs::Js.new(:source => @source, :options => @options).minify end |
#to_js ⇒ Object
2 3 4 |
# File 'lib/zfben_libjs/support_source/coffee.rb', line 2 def to_js compile end |