@dcloudio/uni-cli-shared 3.0.0-alpha-4000220240302001 → 3.0.0-alpha-4000220240306001
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/dist/json/uni-x/index.js +13 -2
- package/package.json +4 -4
package/dist/json/uni-x/index.js
CHANGED
|
@@ -58,8 +58,7 @@ function checkPagesJson(jsonStr, inputDir) {
|
|
|
58
58
|
if (pagePathNodes.length) {
|
|
59
59
|
for (const node of pagePathNodes) {
|
|
60
60
|
const pagePath = node.value ?? '';
|
|
61
|
-
if (
|
|
62
|
-
fs_1.default.existsSync(path_1.default.join(inputDir, pagePath + '.vue'))) {
|
|
61
|
+
if (pageExistsWithCaseSync(path_1.default.join(inputDir, pagePath))) {
|
|
63
62
|
continue;
|
|
64
63
|
}
|
|
65
64
|
const { line, column } = (0, utils_2.offsetToLineColumn)(jsonStr, node.offset);
|
|
@@ -78,6 +77,18 @@ function checkPagesJson(jsonStr, inputDir) {
|
|
|
78
77
|
return true;
|
|
79
78
|
}
|
|
80
79
|
exports.checkPagesJson = checkPagesJson;
|
|
80
|
+
function pageExistsWithCaseSync(pagePath) {
|
|
81
|
+
try {
|
|
82
|
+
const files = fs_1.default.readdirSync(path_1.default.dirname(pagePath));
|
|
83
|
+
const basename = path_1.default.basename(pagePath);
|
|
84
|
+
const uvuePage = basename + '.uvue';
|
|
85
|
+
const vuePage = basename + '.vue';
|
|
86
|
+
return files.some((file) => file === uvuePage || file === vuePage);
|
|
87
|
+
}
|
|
88
|
+
catch (e) {
|
|
89
|
+
return false;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
81
92
|
function findSubPackageRoot(node) {
|
|
82
93
|
const child = node.children?.find((child) => child.type === 'property' &&
|
|
83
94
|
child.children &&
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dcloudio/uni-cli-shared",
|
|
3
|
-
"version": "3.0.0-alpha-
|
|
3
|
+
"version": "3.0.0-alpha-4000220240306001",
|
|
4
4
|
"description": "@dcloudio/uni-cli-shared",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
"@babel/core": "^7.21.3",
|
|
27
27
|
"@babel/parser": "^7.23.5",
|
|
28
28
|
"@babel/types": "^7.20.7",
|
|
29
|
-
"@dcloudio/uni-i18n": "3.0.0-alpha-
|
|
30
|
-
"@dcloudio/uni-shared": "3.0.0-alpha-
|
|
29
|
+
"@dcloudio/uni-i18n": "3.0.0-alpha-4000220240306001",
|
|
30
|
+
"@dcloudio/uni-shared": "3.0.0-alpha-4000220240306001",
|
|
31
31
|
"@intlify/core-base": "9.1.9",
|
|
32
32
|
"@intlify/shared": "9.1.9",
|
|
33
33
|
"@intlify/vue-devtools": "9.1.9",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
},
|
|
68
68
|
"gitHead": "33e807d66e1fe47e2ee08ad9c59247e37b8884da",
|
|
69
69
|
"devDependencies": {
|
|
70
|
-
"@dcloudio/uni-uts-v1": "3.0.0-alpha-
|
|
70
|
+
"@dcloudio/uni-uts-v1": "3.0.0-alpha-4000220240306001",
|
|
71
71
|
"@types/babel__code-frame": "^7.0.6",
|
|
72
72
|
"@types/babel__core": "^7.1.19",
|
|
73
73
|
"@types/debug": "^4.1.7",
|