UNPKG

569 BJavaScriptView Raw
1'use strict';
2
3function __$styleInject(css) {
4 if (!css) return;
5
6 if (typeof window == 'undefined') return;
7 var style = document.createElement('style');
8 style.setAttribute('media', 'screen');
9
10 style.innerHTML = css;
11 document.head.appendChild(style);
12 return css;
13}
14var css = "body .wrap {\n color: #fff;\n}\nbody a {\n font-size: 12px;\n}\n";
15
16var css01 = ".hidden {\n display: none !important;\n}\n.content .header {\n font-size: 12px;\n}\n.content .body {\n color: #333;\n}\n";
17
18console.log('css: ', css);
19console.log('css01: ', css01);
\No newline at end of file