MCPcopy Create free account
hub / github.com/cburgmer/rasterizeHTML.js / cssRulesToText

Function cssRulesToText

src/documentUtil.js:38–42  ·  view source on GitHub ↗
(cssRules)

Source from the content-addressed store, hash-verified

36 };
37
38 var cssRulesToText = function (cssRules) {
39 return asArray(cssRules).reduce(function (cssText, rule) {
40 return cssText + rule.cssText;
41 }, "");
42 };
43
44 var rewriteStyleContent = function (styleElement) {
45 styleElement.textContent = cssRulesToText(styleElement.sheet.cssRules);

Callers 1

rewriteStyleContentFunction · 0.85

Calls 1

asArrayFunction · 0.70

Tested by

no test coverage detected