UNPKG

534 BJavaScriptView Raw
1module.exports = function(content) {
2 if (this.request.match(/\/app\.(css|scss|less|sass)$/)) {
3 return content;
4 }
5 content += `
6 const application = require("tns-core-modules/application");
7 require("tns-core-modules/ui/styling/style-scope");
8
9 exports.forEach(cssExport => {
10 if (cssExport.length > 1 && cssExport[1]) {
11 // applying the second item of the export as it contains the css contents
12 application.addCss(cssExport[1]);
13 }
14 });
15 `;
16
17 return content;
18}
\No newline at end of file