vaderjs 1.3.3-alpha-83 → 1.3.3-alpha-85
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/vader.js +13 -7
package/package.json
CHANGED
package/vader.js
CHANGED
|
@@ -621,9 +621,17 @@ function Compiler(func, file) {
|
|
|
621
621
|
|
|
622
622
|
break;
|
|
623
623
|
case path && path.includes('module.css'):
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
624
|
+
|
|
625
|
+
path = path.replace(';', '')
|
|
626
|
+
path = path.replace(/'/g, '').trim().replace(/"/g, '').trim()
|
|
627
|
+
path = path.replaceAll('.jsx', '.js');
|
|
628
|
+
path = path.replaceAll('../', '');
|
|
629
|
+
|
|
630
|
+
let css = fs.readFileSync(process.cwd() + '/' + path, 'utf8')
|
|
631
|
+
|
|
632
|
+
css = css.replaceAll('.', '')
|
|
633
|
+
newImport = `let ${name} = ${JSON.stringify(parse(css))}`
|
|
634
|
+
string = string.replace(beforeimport, newImport)
|
|
627
635
|
break;
|
|
628
636
|
case path && path.includes('.css'):
|
|
629
637
|
newImport = ``
|
|
@@ -643,8 +651,7 @@ function Compiler(func, file) {
|
|
|
643
651
|
path = '/src/' + path
|
|
644
652
|
} else if (path.startsWith('src') || path.startsWith('public')) {
|
|
645
653
|
path = '/' + path
|
|
646
|
-
}
|
|
647
|
-
console.log(path)
|
|
654
|
+
}
|
|
648
655
|
path = path.replaceAll('.jsx', '.js');
|
|
649
656
|
|
|
650
657
|
|
|
@@ -874,8 +881,7 @@ async function Build() {
|
|
|
874
881
|
|
|
875
882
|
scannedFiles.forEach(async (file) => {
|
|
876
883
|
file = file.split(process.cwd() + '/runtime/')[1]
|
|
877
|
-
|
|
878
|
-
console.log(file)
|
|
884
|
+
|
|
879
885
|
let objCase = {
|
|
880
886
|
...file == "app.js" ? { exit: true } : null,
|
|
881
887
|
...file.includes("index.html") && fs.existsSync(process.cwd() + "/runtime/" + file) ? { exit: true } : null,
|