@dcloudio/uni-cli-shared 3.0.0-alpha-3031320220314002 → 3.0.0-alpha-3040220220310008
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/manifest.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ export declare function normalizeNetworkTimeout(networkTimeout?: Partial<typeof
|
|
|
19
19
|
downloadFile: number;
|
|
20
20
|
};
|
|
21
21
|
export declare function getUniStatistics(inputDir: string, platform: UniApp.PLATFORM): any;
|
|
22
|
-
export declare function
|
|
22
|
+
export declare function isEnableUniPushV2(inputDir: string, platform: UniApp.PLATFORM): boolean;
|
|
23
23
|
export declare function isUniPushOffline(inputDir: string): boolean;
|
|
24
24
|
export declare function getRouterOptions(manifestJson: Record<string, any>): {
|
|
25
25
|
mode?: 'history' | 'hash';
|
package/dist/json/manifest.js
CHANGED
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.getDevServerOptions = exports.isEnableTreeShaking = exports.getRouterOptions = exports.isUniPushOffline = exports.
|
|
6
|
+
exports.getDevServerOptions = exports.isEnableTreeShaking = exports.getRouterOptions = exports.isUniPushOffline = exports.isEnableUniPushV2 = exports.getUniStatistics = exports.normalizeNetworkTimeout = exports.parseCompatConfigOnce = exports.parseRpx2UnitOnce = exports.parseManifestJsonOnce = exports.parseManifestJson = void 0;
|
|
7
7
|
const fs_1 = __importDefault(require("fs"));
|
|
8
8
|
const path_1 = __importDefault(require("path"));
|
|
9
9
|
const shared_1 = require("@vue/shared");
|
|
@@ -47,15 +47,20 @@ function getUniStatistics(inputDir, platform) {
|
|
|
47
47
|
return (0, shared_1.extend)({}, manifest.uniStatistics, manifest[platform] && manifest[platform].uniStatistics);
|
|
48
48
|
}
|
|
49
49
|
exports.getUniStatistics = getUniStatistics;
|
|
50
|
-
function
|
|
50
|
+
function isEnableUniPushV2(inputDir, platform) {
|
|
51
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
51
52
|
const manifest = (0, exports.parseManifestJsonOnce)(inputDir);
|
|
52
|
-
|
|
53
|
+
if (platform === 'app') {
|
|
54
|
+
return (((_e = (_d = (_c = (_b = (_a = manifest['app-plus']) === null || _a === void 0 ? void 0 : _a.distribute) === null || _b === void 0 ? void 0 : _b.sdkConfigs) === null || _c === void 0 ? void 0 : _c.push) === null || _d === void 0 ? void 0 : _d.unipush) === null || _e === void 0 ? void 0 : _e.version) ==
|
|
55
|
+
'2');
|
|
56
|
+
}
|
|
57
|
+
return ((_g = (_f = manifest[platform]) === null || _f === void 0 ? void 0 : _f.unipush) === null || _g === void 0 ? void 0 : _g.enable) === true;
|
|
53
58
|
}
|
|
54
|
-
exports.
|
|
59
|
+
exports.isEnableUniPushV2 = isEnableUniPushV2;
|
|
55
60
|
function isUniPushOffline(inputDir) {
|
|
56
61
|
var _a, _b, _c, _d, _e;
|
|
57
62
|
const manifest = (0, exports.parseManifestJsonOnce)(inputDir);
|
|
58
|
-
return (((_e = (_d = (_c = (_b = (_a = manifest
|
|
63
|
+
return (((_e = (_d = (_c = (_b = (_a = manifest['app-plus']) === null || _a === void 0 ? void 0 : _a.distribute) === null || _b === void 0 ? void 0 : _b.sdkConfigs) === null || _c === void 0 ? void 0 : _c.push) === null || _d === void 0 ? void 0 : _d.unipush) === null || _e === void 0 ? void 0 : _e.offline) ===
|
|
59
64
|
true);
|
|
60
65
|
}
|
|
61
66
|
exports.isUniPushOffline = isUniPushOffline;
|
package/dist/json/mp/jsonFile.js
CHANGED
|
@@ -122,12 +122,12 @@ exports.findMiniProgramUsingComponents = findMiniProgramUsingComponents;
|
|
|
122
122
|
function findMiniProgramUsingComponent(usingComponents, componentsDir) {
|
|
123
123
|
return Object.keys(usingComponents).reduce((res, name) => {
|
|
124
124
|
const path = usingComponents[name];
|
|
125
|
-
if (
|
|
126
|
-
res[name] = 'component';
|
|
127
|
-
}
|
|
128
|
-
else if (path.includes('plugin://')) {
|
|
125
|
+
if (path.includes('plugin://')) {
|
|
129
126
|
res[name] = 'plugin';
|
|
130
127
|
}
|
|
128
|
+
else if (componentsDir && path.includes(componentsDir + '/')) {
|
|
129
|
+
res[name] = 'component';
|
|
130
|
+
}
|
|
131
131
|
return res;
|
|
132
132
|
}, {});
|
|
133
133
|
}
|
package/dist/json/mp/types.d.ts
CHANGED
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-3040220220310008",
|
|
4
4
|
"description": "@dcloudio/uni-cli-shared",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -21,15 +21,15 @@
|
|
|
21
21
|
"@babel/core": "^7.17.2",
|
|
22
22
|
"@babel/parser": "^7.16.4",
|
|
23
23
|
"@babel/types": "^7.16.8",
|
|
24
|
-
"@dcloudio/uni-i18n": "3.0.0-alpha-
|
|
25
|
-
"@dcloudio/uni-shared": "3.0.0-alpha-
|
|
24
|
+
"@dcloudio/uni-i18n": "3.0.0-alpha-3040220220310008",
|
|
25
|
+
"@dcloudio/uni-shared": "3.0.0-alpha-3040220220310008",
|
|
26
26
|
"@rollup/pluginutils": "^4.1.2",
|
|
27
27
|
"@vue/compiler-core": "3.2.31",
|
|
28
28
|
"@vue/compiler-dom": "3.2.31",
|
|
29
29
|
"@vue/compiler-sfc": "3.2.31",
|
|
30
30
|
"@vue/server-renderer": "3.2.31",
|
|
31
31
|
"@vue/shared": "3.2.31",
|
|
32
|
-
"autoprefixer": "^10.4.
|
|
32
|
+
"autoprefixer": "^10.4.4",
|
|
33
33
|
"base64url": "^3.0.1",
|
|
34
34
|
"chokidar": "^3.5.3",
|
|
35
35
|
"compare-versions": "^3.6.0",
|