Class: Malt::Formats::Sass

Inherits:
Abstract show all
Defined in:
lib/malt/formats/sass.rb

Overview

Sass Format

Instance Attribute Summary

Attributes inherited from Abstract

#options

Instance Method Summary collapse

Methods inherited from Abstract

engine, #engine, extensions, #extensions, #file, #parse_type_and_data, #refile, register, #render, #subtype, #text, #to, #to_s, #type

Instance Method Details

#css(data = nil, &yld) ⇒ Object



14
15
16
# File 'lib/malt/formats/sass.rb', line 14

def css(data=nil, &yld)
  render_engine.render(:format=>:css, :text=>text, :file=>file, :type=>type)
end

#to_css(data = nil, &yld) ⇒ Object



19
20
21
22
# File 'lib/malt/formats/sass.rb', line 19

def to_css(data=nil, &yld)
  result = css(data, &yld)
  CSS.new(:text=>result, :file=>refile(:css), :type=>:css)
end