We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aacf134 commit 282dd8dCopy full SHA for 282dd8d
index.js
@@ -1,11 +1,24 @@
1
2
+/**
3
+ * Stringfy the given AST `node`.
4
+ *
5
+ * @param {Object} node
6
+ * @param {Object} options
7
+ * @return {String}
8
+ * @api public
9
+ */
10
+
11
module.exports = function(node, options){
12
options = options || {};
13
return options.compress
14
? node.stylesheet.rules.map(rule(options)).join('')
15
: node.stylesheet.rules.map(rule(options)).join('\n\n');
16
};
17
18
19
+ * Compile rule.
20
21
22
function rule(options) {
23
if (options.compress) {
24
return function(rule) {
@@ -24,6 +37,10 @@ function rule(options) {
37
}
25
38
26
39
40
41
+ * Compile declarations.
42
43
27
44
function declaration(options) {
28
45
29
46
return function(decl){
0 commit comments