support windows line endings

pull/248/head
Fabian Jakobs 2016-02-05 20:42:53 +00:00
rodzic 8fed2e6b28
commit df687ee807
1 zmienionych plików z 1 dodań i 1 usunięć

2
node_modules/architect-build/build.js wygenerowano vendored
Wyświetl plik

@ -338,7 +338,7 @@ function rewriteDefines(sources, opts){
// include literal
}
else if (pkg.id.indexOf("text!") > -1) {
var source = pkg.source.replace(/\\/g, '\\\\').replace(/\n/g, "\\n").replace(/"/g, '\\"');
var source = pkg.source.replace(/\\/g, '\\\\').replace(/\r?\n/g, "\\n").replace(/"/g, '\\"');
pkg.source = 'define("' + pkg.id + '",[],"'
+ source
+ '");';