Class: Middleman::Renderers::Less::LocalLoadingLessTemplate

Inherits:
Tilt::LessTemplate
  • Object
show all
Defined in:
lib/middleman-core/renderers/less.rb

Overview

A SassTemplate for Tilt which outputs debug messages

Instance Method Summary collapse

Instance Method Details

#prepareObject


25
26
27
28
29
30
31
32
# File 'lib/middleman-core/renderers/less.rb', line 25

def prepare
  if ::Less.const_defined? :Engine
    @engine = ::Less::Engine.new(data)
  else
    parser = ::Less::Parser.new({}.merge!(options).merge!(filename: eval_file, line: line, paths: ['.', File.dirname(eval_file)]))
    @engine = parser.parse(data)
  end
end