source: imaps-frontend/node_modules/postcss/lib/declaration.js@ d565449

main
Last change on this file since d565449 was d565449, checked in by stefan toskovski <stefantoska84@…>, 4 weeks ago

Update repo after prototype presentation

  • Property mode set to 100644
File size: 495 bytes
RevLine 
[d565449]1'use strict'
2
3let Node = require('./node')
4
5class Declaration extends Node {
6 constructor(defaults) {
7 if (
8 defaults &&
9 typeof defaults.value !== 'undefined' &&
10 typeof defaults.value !== 'string'
11 ) {
12 defaults = { ...defaults, value: String(defaults.value) }
13 }
14 super(defaults)
15 this.type = 'decl'
16 }
17
18 get variable() {
19 return this.prop.startsWith('--') || this.prop[0] === '$'
20 }
21}
22
23module.exports = Declaration
24Declaration.default = Declaration
Note: See TracBrowser for help on using the repository browser.