MCPcopy Index your code
hub / github.com/postcss/postcss / atrule

Method atrule

lib/stringifier.js:39–56  ·  view source on GitHub ↗
(node, semicolon)

Source from the content-addressed store, hash-verified

37 }
38
39 atrule(node, semicolon) {
40 let raws = node.raws
41 let name = '@' + node.name
42 let params = node.params ? this.rawValue(node, 'params') : ''
43
44 if (typeof raws.afterName !== 'undefined') {
45 name += raws.afterName
46 } else if (params) {
47 name += ' '
48 }
49
50 if (node.nodes) {
51 this.block(node, name + params)
52 } else {
53 let end = (raws.between || '') + (semicolon ? ';' : '')
54 this.builder(escapeHTMLInCSS(name + params + end), node)
55 }
56 }
57
58 beforeAfter(node, detect) {
59 let value

Callers

nothing calls this directly

Calls 3

rawValueMethod · 0.95
blockMethod · 0.95
escapeHTMLInCSSFunction · 0.85

Tested by

no test coverage detected