UNPKG

node-less

Version:

Less Compiler For Node

26 lines (22 loc) 649 B
(function (module) { var Assignment = function (key, val) { this.key = key; this.value = val; }; Assignment.prototype = { type: "Assignment", accept: function (visitor) { this.value = visitor.visit(this.value); }, toCSS: function () { return this.key + '=' + (this.value.toCSS ? this.value.toCSS() : this.value); }, eval: function (env) { if (this.value.eval) { return new Assignment(this.key, this.value.eval(env)); } return this; } }; module.exports = Assignment; })(module);