MOBILE-3361 ionic: Exclude windows phone stylesheets

main
Pau Ferrer Ocaña 2020-02-26 17:13:44 +01:00
parent 04a6aae270
commit bcbd9a7ca5
2 changed files with 11 additions and 0 deletions

View File

@ -5,5 +5,11 @@ module.exports = {
'node_modules/ionicons/dist/scss', 'node_modules/ionicons/dist/scss',
'node_modules/ionic-angular/fonts', 'node_modules/ionic-angular/fonts',
'node_modules/font-awesome/scss' 'node_modules/font-awesome/scss'
],
includeFiles: [
/\.(s(c|a)ss)$/i
],
excludeFiles: [
/\.(wp).(scss)$/i
] ]
}; };

View File

@ -317,6 +317,11 @@ function getReplace(capture, baseDir, paths, parsedFiles) {
var parse = path.parse(path.resolve(baseDir, capture + '.scss')); var parse = path.parse(path.resolve(baseDir, capture + '.scss'));
var file = parse.dir + '/' + parse.name; var file = parse.dir + '/' + parse.name;
if (file.slice(-3) === '.wp') {
console.log('Windows Phone not supported "' + capture);
// File was already parsed, leave the import commented.
return '// @import "' + capture + '";';
}
if (!fs.existsSync(file + '.scss')) { if (!fs.existsSync(file + '.scss')) {
// File not found, might be a partial file. // File not found, might be a partial file.