source: frontend/node_modules/tailwindcss/src/value-parser/index.js

Last change on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 11 days ago

Fix frontend appearance

  • Property mode set to 100644
File size: 594 bytes
Line 
1var parse = require('./parse')
2var walk = require('./walk')
3var stringify = require('./stringify')
4
5function ValueParser(value) {
6 if (this instanceof ValueParser) {
7 this.nodes = parse(value)
8 return this
9 }
10 return new ValueParser(value)
11}
12
13ValueParser.prototype.toString = function () {
14 return Array.isArray(this.nodes) ? stringify(this.nodes) : ''
15}
16
17ValueParser.prototype.walk = function (cb, bubble) {
18 walk(this.nodes, cb, bubble)
19 return this
20}
21
22ValueParser.unit = require('./unit')
23
24ValueParser.walk = walk
25
26ValueParser.stringify = stringify
27
28module.exports = ValueParser
Note: See TracBrowser for help on using the repository browser.