Module | Less::StyleSheet::Import1
In: | lib/sass/less.rb

@import statements. Less handles these during parse-time, so we want to wrap them up as a node in the tree. We also include the nodes, though, since we want to have access to the mixins so we can tell if they take arguments or not. The included nodes are hidden so they don‘t appear in the output.

### Methods

build build_with_sass

### External Aliases

build | -> | build_without_sass

### Public Instance methods

build(env)

Alias for build_with_sass

build_with_sass(env)

[Source]

         # File lib/sass/less.rb, line 107
    107:       def build_with_sass(env)
    108:         line = input.line_of(interval.first)
    109:         import = Sass::Tree::ImportNode.new(url.value.gsub(/\.less$/, ''))
    110:         import.line = input.line_of(interval.first)
    111:         env << Node::SassNode.new(import)
    112:         old_rules = env.rules.dup
    113:         build_without_sass env
    114:         (env.rules - old_rules).each {|r| r.hide_in_sass = true}
    115:       rescue ImportError => e
    116:         raise Sass::SyntaxError.new("File to import #{url.text_value} not found or unreadable", :line => line)
    117:       end

[Validate]