Module: Grass::Render::YuiRenderer

Includes:
Renderer
Included in:
Stylesheet
Defined in:
lib/grass/render/yui_renderer.rb

Constant Summary collapse

YUI_JAR_FILE =
"#{Grass.gem_root}/vendor/yuicompressor-2.4.8.jar"
CSS =
YUI::CssCompressor.new({jar_file: YUI_JAR_FILE})
JS =
YUI::JavaScriptCompressor.new({jar_file: YUI_JAR_FILE, munge: true})

Instance Method Summary collapse

Methods included from Renderer

#initialize, #templates

Methods included from Helpers::RenderHelper

#include_partial, #render_content, #render_partial

Instance Method Details

#compress(source) ⇒ Object



17
18
19
# File 'lib/grass/render/yui_renderer.rb', line 17

def compress source
  compressor.compress(source)
end

#compressorObject

Raises:

  • (NotImplementedError)


21
22
23
# File 'lib/grass/render/yui_renderer.rb', line 21

def compressor
  raise NotImplementedError
end

#renderObject



13
14
15
# File 'lib/grass/render/yui_renderer.rb', line 13

def render 
  compress(super)
end