You are here

public function SassCompactRenderer::renderDirective in Sassy 7

Same name and namespace in other branches
  1. 7.3 phpsass/renderers/SassCompactRenderer.php \SassCompactRenderer::renderDirective()

* Renders a directive. *

Parameters

SassNode the node being rendered: * @param array properties of the directive * @return string the rendered directive

Overrides SassCompressedRenderer::renderDirective

1 method overrides SassCompactRenderer::renderDirective()
SassNestedRenderer::renderDirective in phamlp/sass/renderers/SassNestedRenderer.php
* Renders a directive. *

File

phamlp/sass/renderers/SassCompactRenderer.php, line 60

Class

SassCompactRenderer
SassCompactRenderer class. Each CSS rule takes up only one line, with every property defined on that line. Nested rules are placed next to each other with no newline, while groups of rules have newlines between…

Code

public function renderDirective($node, $properties) {
  return str_replace("\n", '', parent::renderDirective($node, $properties)) . "\n\n";
}