@dcloudio/uni-cli-shared 3.0.0-alpha-4000120240201002 → 3.0.0-alpha-4000220240228001
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/env/define.d.ts +1 -0
- package/dist/env/define.js +1 -0
- package/dist/hbx/alias.js +33 -9
- package/dist/json/manifest.js +4 -0
- package/dist/messages/en.d.ts +1 -0
- package/dist/messages/en.js +1 -0
- package/dist/messages/index.d.ts +2 -0
- package/dist/messages/zh_CN.d.ts +1 -0
- package/dist/messages/zh_CN.js +1 -0
- package/dist/uni_modules.d.ts +6 -0
- package/dist/uni_modules.js +12 -1
- package/dist/vite/plugins/uts/uni_modules.d.ts +7 -0
- package/dist/vite/plugins/uts/uni_modules.js +57 -9
- package/dist/vite/plugins/vitejs/plugins/css.js +2 -1
- package/package.json +4 -4
package/dist/env/define.d.ts
CHANGED
|
@@ -12,6 +12,7 @@ export declare function initDefine(stringifyBoolean?: boolean): {
|
|
|
12
12
|
'process.env.UNI_COMPILER_VERSION': string;
|
|
13
13
|
'process.env.RUN_BY_HBUILDERX': string | boolean;
|
|
14
14
|
'process.env.UNI_AUTOMATOR_WS_ENDPOINT': string;
|
|
15
|
+
'process.env.UNI_AUTOMATOR_APP_WEBVIEW_SRC': string;
|
|
15
16
|
'process.env.UNI_CLOUD_PROVIDER': string;
|
|
16
17
|
'process.env.UNICLOUD_DEBUG': string;
|
|
17
18
|
'process.env.VUE_APP_PLATFORM': string;
|
package/dist/env/define.js
CHANGED
|
@@ -27,6 +27,7 @@ function initDefine(stringifyBoolean = false) {
|
|
|
27
27
|
? JSON.stringify(isRunByHBuilderX)
|
|
28
28
|
: isRunByHBuilderX,
|
|
29
29
|
'process.env.UNI_AUTOMATOR_WS_ENDPOINT': JSON.stringify(process.env.UNI_AUTOMATOR_WS_ENDPOINT || ''),
|
|
30
|
+
'process.env.UNI_AUTOMATOR_APP_WEBVIEW_SRC': JSON.stringify(process.env.UNI_AUTOMATOR_APP_WEBVIEW_SRC || ''),
|
|
30
31
|
'process.env.UNI_CLOUD_PROVIDER': JSON.stringify(process.env.UNI_CLOUD_PROVIDER || ''),
|
|
31
32
|
'process.env.UNICLOUD_DEBUG': JSON.stringify(process.env.UNICLOUD_DEBUG || ''),
|
|
32
33
|
// 兼容旧版本
|
package/dist/hbx/alias.js
CHANGED
|
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
6
6
|
exports.formatInstallHBuilderXPluginTips = exports.moduleAliasFormatter = exports.installHBuilderXPlugin = exports.initModuleAlias = void 0;
|
|
7
7
|
const path_1 = __importDefault(require("path"));
|
|
8
8
|
const module_alias_1 = __importDefault(require("module-alias"));
|
|
9
|
-
const resolve_1 = __importDefault(require("resolve"));
|
|
10
9
|
const env_1 = require("./env");
|
|
11
10
|
const hbxPlugins = {
|
|
12
11
|
// typescript: 'compile-typescript/node_modules/typescript',
|
|
@@ -38,14 +37,39 @@ function initModuleAlias() {
|
|
|
38
37
|
Object.keys(hbxPlugins).forEach((name) => {
|
|
39
38
|
module_alias_1.default.addAlias(name, path_1.default.resolve(process.env.UNI_HBUILDERX_PLUGINS, hbxPlugins[name]));
|
|
40
39
|
});
|
|
41
|
-
//
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
40
|
+
// web 平台用了 vite 内置 css 插件,该插件会加载预编译器如scss、less等,需要转向到 HBuilderX 的对应编译器插件
|
|
41
|
+
if (process.env.UNI_PLATFORM === 'h5' ||
|
|
42
|
+
process.env.UNI_PLATFORM === 'web') {
|
|
43
|
+
// https://github.com/vitejs/vite/blob/main/packages/vite/src/node/packages.ts#L92
|
|
44
|
+
// 拦截预编译器
|
|
45
|
+
const join = path_1.default.join;
|
|
46
|
+
path_1.default.join = function (...paths) {
|
|
47
|
+
if (paths.length === 4) {
|
|
48
|
+
// path.join(basedir, 'node_modules', pkgName, 'package.json')
|
|
49
|
+
// const basedir = paths[0]
|
|
50
|
+
const nodeModules = paths[1]; // = node_modules
|
|
51
|
+
const pkgName = paths[2];
|
|
52
|
+
const packageJson = paths[3]; // = package.json
|
|
53
|
+
if (nodeModules === 'node_modules' &&
|
|
54
|
+
packageJson === 'package.json' &&
|
|
55
|
+
hbxPlugins[pkgName]) {
|
|
56
|
+
return path_1.default.resolve(process.env.UNI_HBUILDERX_PLUGINS, hbxPlugins[pkgName], packageJson);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
return join(...paths);
|
|
60
|
+
};
|
|
61
|
+
// https://github.com/vitejs/vite/blob/892916d040a035edde1add93c192e0b0c5c9dd86/packages/vite/src/node/plugins/css.ts#L1481
|
|
62
|
+
// const oldSync = resovle.sync
|
|
63
|
+
// resovle.sync = (id: string, opts?: SyncOpts) => {
|
|
64
|
+
// if ((hbxPlugins as any)[id]) {
|
|
65
|
+
// return path.resolve(
|
|
66
|
+
// process.env.UNI_HBUILDERX_PLUGINS,
|
|
67
|
+
// hbxPlugins[id as keyof typeof hbxPlugins]
|
|
68
|
+
// )
|
|
69
|
+
// }
|
|
70
|
+
// return oldSync(id, opts)
|
|
71
|
+
// }
|
|
72
|
+
}
|
|
49
73
|
}
|
|
50
74
|
}
|
|
51
75
|
exports.initModuleAlias = initModuleAlias;
|
package/dist/json/manifest.js
CHANGED
|
@@ -97,6 +97,10 @@ function getRouterOptions(manifestJson) {
|
|
|
97
97
|
}
|
|
98
98
|
exports.getRouterOptions = getRouterOptions;
|
|
99
99
|
function isEnableTreeShaking(manifestJson) {
|
|
100
|
+
// 自动化测试时,一定不摇树
|
|
101
|
+
if (process.env.UNI_AUTOMATOR_WS_ENDPOINT) {
|
|
102
|
+
return false;
|
|
103
|
+
}
|
|
100
104
|
return manifestJson.h5?.optimization?.treeShaking?.enable !== false;
|
|
101
105
|
}
|
|
102
106
|
exports.isEnableTreeShaking = isEnableTreeShaking;
|
package/dist/messages/en.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ declare const _default: {
|
|
|
5
5
|
readonly 'dev.exclusion': "Please configure the antivirus software to set up an exclusion list for scanning, reducing system resource consumption. [详情](https://uniapp.dcloud.net.cn/uni-app-x/compiler/#tips)";
|
|
6
6
|
readonly 'dev.performance.nvue': "Especially the sourcemap of app-nvue has a greater impact";
|
|
7
7
|
readonly 'dev.performance.mp': "To officially release, please click the release menu or use the cli release command to release";
|
|
8
|
+
readonly 'dev.performance.web': "\nVite is compiled on demand, and clicking on an uncompiled page at runtime will compile first and then load, resulting in a slower display, and there is no such problem after release.";
|
|
8
9
|
readonly 'build.done': "DONE Build complete.";
|
|
9
10
|
readonly 'dev.watching.start': "Compiling...";
|
|
10
11
|
readonly 'dev.watching.end': "DONE Build complete. Watching for changes...";
|
package/dist/messages/en.js
CHANGED
|
@@ -7,6 +7,7 @@ exports.default = {
|
|
|
7
7
|
'dev.exclusion': 'Please configure the antivirus software to set up an exclusion list for scanning, reducing system resource consumption. [详情](https://uniapp.dcloud.net.cn/uni-app-x/compiler/#tips)',
|
|
8
8
|
'dev.performance.nvue': 'Especially the sourcemap of app-nvue has a greater impact',
|
|
9
9
|
'dev.performance.mp': 'To officially release, please click the release menu or use the cli release command to release',
|
|
10
|
+
'dev.performance.web': '\nVite is compiled on demand, and clicking on an uncompiled page at runtime will compile first and then load, resulting in a slower display, and there is no such problem after release.',
|
|
10
11
|
'build.done': 'DONE Build complete.',
|
|
11
12
|
'dev.watching.start': 'Compiling...',
|
|
12
13
|
'dev.watching.end': 'DONE Build complete. Watching for changes...',
|
package/dist/messages/index.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ export declare const M: {
|
|
|
5
5
|
readonly 'dev.exclusion': "请在杀毒软件中设置扫描排除名单,减少系统资源消耗。[详情](https://uniapp.dcloud.net.cn/uni-app-x/compiler/#tips)";
|
|
6
6
|
readonly 'dev.performance.nvue': "尤其是 app-nvue 的 sourcemap 影响较大";
|
|
7
7
|
readonly 'dev.performance.mp': "若要正式发布,请点击发行菜单或使用 cli 发布命令进行发布";
|
|
8
|
+
readonly 'dev.performance.web': "\nvite是按需编译,运行时点击某个未编译页面会先编译后加载,导致显示较慢,发行后无此问题。";
|
|
8
9
|
readonly 'build.done': "DONE Build complete.";
|
|
9
10
|
readonly 'dev.watching.start': "开始差量编译...";
|
|
10
11
|
readonly 'dev.watching.end': "DONE Build complete. Watching for changes...";
|
|
@@ -49,6 +50,7 @@ export declare const M: {
|
|
|
49
50
|
readonly 'dev.exclusion': "Please configure the antivirus software to set up an exclusion list for scanning, reducing system resource consumption. [详情](https://uniapp.dcloud.net.cn/uni-app-x/compiler/#tips)";
|
|
50
51
|
readonly 'dev.performance.nvue': "Especially the sourcemap of app-nvue has a greater impact";
|
|
51
52
|
readonly 'dev.performance.mp': "To officially release, please click the release menu or use the cli release command to release";
|
|
53
|
+
readonly 'dev.performance.web': "\nVite is compiled on demand, and clicking on an uncompiled page at runtime will compile first and then load, resulting in a slower display, and there is no such problem after release.";
|
|
52
54
|
readonly 'build.done': "DONE Build complete.";
|
|
53
55
|
readonly 'dev.watching.start': "Compiling...";
|
|
54
56
|
readonly 'dev.watching.end': "DONE Build complete. Watching for changes...";
|
package/dist/messages/zh_CN.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ declare const _default: {
|
|
|
5
5
|
readonly 'dev.exclusion': "请在杀毒软件中设置扫描排除名单,减少系统资源消耗。[详情](https://uniapp.dcloud.net.cn/uni-app-x/compiler/#tips)";
|
|
6
6
|
readonly 'dev.performance.nvue': "尤其是 app-nvue 的 sourcemap 影响较大";
|
|
7
7
|
readonly 'dev.performance.mp': "若要正式发布,请点击发行菜单或使用 cli 发布命令进行发布";
|
|
8
|
+
readonly 'dev.performance.web': "\nvite是按需编译,运行时点击某个未编译页面会先编译后加载,导致显示较慢,发行后无此问题。";
|
|
8
9
|
readonly 'build.done': "DONE Build complete.";
|
|
9
10
|
readonly 'dev.watching.start': "开始差量编译...";
|
|
10
11
|
readonly 'dev.watching.end': "DONE Build complete. Watching for changes...";
|
package/dist/messages/zh_CN.js
CHANGED
|
@@ -7,6 +7,7 @@ exports.default = {
|
|
|
7
7
|
'dev.exclusion': '请在杀毒软件中设置扫描排除名单,减少系统资源消耗。[详情](https://uniapp.dcloud.net.cn/uni-app-x/compiler/#tips)',
|
|
8
8
|
'dev.performance.nvue': '尤其是 app-nvue 的 sourcemap 影响较大',
|
|
9
9
|
'dev.performance.mp': '若要正式发布,请点击发行菜单或使用 cli 发布命令进行发布',
|
|
10
|
+
'dev.performance.web': '\nvite是按需编译,运行时点击某个未编译页面会先编译后加载,导致显示较慢,发行后无此问题。',
|
|
10
11
|
'build.done': 'DONE Build complete.',
|
|
11
12
|
'dev.watching.start': '开始差量编译...',
|
|
12
13
|
'dev.watching.end': 'DONE Build complete. Watching for changes...',
|
package/dist/uni_modules.d.ts
CHANGED
|
@@ -15,6 +15,12 @@ export type Defines = {
|
|
|
15
15
|
export interface Exports {
|
|
16
16
|
[name: string]: Define | Defines | false;
|
|
17
17
|
}
|
|
18
|
+
export declare function getUniExtApiProviders(): {
|
|
19
|
+
plugin: string;
|
|
20
|
+
service: string;
|
|
21
|
+
name?: string | undefined;
|
|
22
|
+
servicePlugin?: string | undefined;
|
|
23
|
+
}[];
|
|
18
24
|
export declare function parseUniExtApis(vite: boolean | undefined, platform: typeof process.env.UNI_UTS_PLATFORM, language?: UTSTargetLanguage): Injects;
|
|
19
25
|
export type Injects = {
|
|
20
26
|
[name: string]: string | [string, string] | [string, string, DefineOptions['app']] | false;
|
package/dist/uni_modules.js
CHANGED
|
@@ -3,10 +3,15 @@ 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.parseInjects = exports.parseUniExtApis = void 0;
|
|
6
|
+
exports.parseInjects = exports.parseUniExtApis = exports.getUniExtApiProviders = void 0;
|
|
7
7
|
// 重要:此文件编译后的js,需同步至 vue2 编译器中 uni-cli-shared/lib/uts/uni_modules.js
|
|
8
8
|
const path_1 = __importDefault(require("path"));
|
|
9
9
|
const fs_extra_1 = __importDefault(require("fs-extra"));
|
|
10
|
+
const extApiProviders = [];
|
|
11
|
+
function getUniExtApiProviders() {
|
|
12
|
+
return extApiProviders;
|
|
13
|
+
}
|
|
14
|
+
exports.getUniExtApiProviders = getUniExtApiProviders;
|
|
10
15
|
function parseUniExtApis(vite = true, platform, language = 'javascript') {
|
|
11
16
|
if (!process.env.UNI_INPUT_DIR) {
|
|
12
17
|
return {};
|
|
@@ -16,6 +21,7 @@ function parseUniExtApis(vite = true, platform, language = 'javascript') {
|
|
|
16
21
|
return {};
|
|
17
22
|
}
|
|
18
23
|
const injects = {};
|
|
24
|
+
extApiProviders.length = 0;
|
|
19
25
|
fs_extra_1.default.readdirSync(uniModulesDir).forEach((uniModuleDir) => {
|
|
20
26
|
// 必须以 uni- 开头
|
|
21
27
|
if (!uniModuleDir.startsWith('uni-')) {
|
|
@@ -33,6 +39,11 @@ function parseUniExtApis(vite = true, platform, language = 'javascript') {
|
|
|
33
39
|
exports = pkg.uni_modules['uni-ext-api'];
|
|
34
40
|
}
|
|
35
41
|
if (exports) {
|
|
42
|
+
const provider = exports.provider;
|
|
43
|
+
if (provider && provider.service) {
|
|
44
|
+
provider.plugin = uniModuleDir;
|
|
45
|
+
extApiProviders.push(provider);
|
|
46
|
+
}
|
|
36
47
|
const curInjects = parseInjects(vite, platform, language, `@/uni_modules/${uniModuleDir}`, uniModuleRootDir, exports);
|
|
37
48
|
Object.assign(injects, curInjects);
|
|
38
49
|
}
|
|
@@ -6,4 +6,11 @@ interface UniUTSPluginOptions {
|
|
|
6
6
|
}
|
|
7
7
|
export declare const utsPlugins: Set<string>;
|
|
8
8
|
export declare function uniUTSUniModulesPlugin(options?: UniUTSPluginOptions): Plugin;
|
|
9
|
+
export declare function buildUniExtApiProviders(): Promise<void>;
|
|
10
|
+
export declare function resolveExtApiProvider(pkg: Record<string, any>): {
|
|
11
|
+
name?: string | undefined;
|
|
12
|
+
plugin?: string | undefined;
|
|
13
|
+
service: string;
|
|
14
|
+
servicePlugin: string;
|
|
15
|
+
} | undefined;
|
|
9
16
|
export {};
|
|
@@ -3,19 +3,59 @@ 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.uniUTSUniModulesPlugin = exports.utsPlugins = void 0;
|
|
6
|
+
exports.resolveExtApiProvider = exports.buildUniExtApiProviders = exports.uniUTSUniModulesPlugin = exports.utsPlugins = void 0;
|
|
7
|
+
const fs_1 = __importDefault(require("fs"));
|
|
7
8
|
const path_1 = __importDefault(require("path"));
|
|
8
9
|
const uni_shared_1 = require("@dcloudio/uni-shared");
|
|
9
10
|
const uts_1 = require("../../../uts");
|
|
10
11
|
const utils_1 = require("../../utils");
|
|
12
|
+
const uni_modules_1 = require("../../../uni_modules");
|
|
11
13
|
const UTSProxyRE = /\?uts-proxy$/;
|
|
12
14
|
function isUTSProxy(id) {
|
|
13
15
|
return UTSProxyRE.test(id);
|
|
14
16
|
}
|
|
15
17
|
const utsModuleCaches = new Map();
|
|
16
18
|
exports.utsPlugins = new Set();
|
|
19
|
+
let uniExtApiCompiler = async () => { };
|
|
17
20
|
function uniUTSUniModulesPlugin(options = {}) {
|
|
18
21
|
process.env.UNI_UTS_USING_ROLLUP = 'true';
|
|
22
|
+
const compilePlugin = (pluginDir) => {
|
|
23
|
+
exports.utsPlugins.add(path_1.default.basename(pluginDir));
|
|
24
|
+
const pkgJson = require(path_1.default.join(pluginDir, 'package.json'));
|
|
25
|
+
const extApiProvider = resolveExtApiProvider(pkgJson);
|
|
26
|
+
// 如果是 provider 扩展,需要判断 provider 的宿主插件是否在本地,在的话,自动导入该宿主插件包名
|
|
27
|
+
let uniExtApiProviderServicePlugin = '';
|
|
28
|
+
if (extApiProvider?.servicePlugin) {
|
|
29
|
+
if (fs_1.default.existsSync(path_1.default.resolve(process.env.UNI_INPUT_DIR, 'uni_modules', extApiProvider.servicePlugin))) {
|
|
30
|
+
uniExtApiProviderServicePlugin = extApiProvider.servicePlugin;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
return (0, uts_1.resolveUTSCompiler)().compile(pluginDir, {
|
|
34
|
+
isX: !!options.x,
|
|
35
|
+
isSingleThread: !!options.isSingleThread,
|
|
36
|
+
isPlugin: true,
|
|
37
|
+
extApis: options.extApis,
|
|
38
|
+
sourceMap: process.env.NODE_ENV === 'development',
|
|
39
|
+
transform: {
|
|
40
|
+
uniExtApiProviderName: extApiProvider?.name,
|
|
41
|
+
uniExtApiProviderService: extApiProvider?.service,
|
|
42
|
+
uniExtApiProviderServicePlugin,
|
|
43
|
+
},
|
|
44
|
+
});
|
|
45
|
+
};
|
|
46
|
+
uniExtApiCompiler = async () => {
|
|
47
|
+
// 获取 provider 扩展
|
|
48
|
+
const plugins = (0, uni_modules_1.getUniExtApiProviders)().filter((provider) => !exports.utsPlugins.has(provider.plugin));
|
|
49
|
+
for (const plugin of plugins) {
|
|
50
|
+
const result = await compilePlugin(path_1.default.resolve(process.env.UNI_INPUT_DIR, 'uni_modules', plugin.plugin));
|
|
51
|
+
if (result) {
|
|
52
|
+
// 时机不对,不能addWatch
|
|
53
|
+
// result.deps.forEach((dep) => {
|
|
54
|
+
// this.addWatchFile(dep)
|
|
55
|
+
// })
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
};
|
|
19
59
|
return {
|
|
20
60
|
name: 'uni:uts-uni_modules',
|
|
21
61
|
apply: 'build',
|
|
@@ -64,14 +104,7 @@ function uniUTSUniModulesPlugin(options = {}) {
|
|
|
64
104
|
});
|
|
65
105
|
}
|
|
66
106
|
const compile = (0, uni_shared_1.once)(() => {
|
|
67
|
-
|
|
68
|
-
return (0, uts_1.resolveUTSCompiler)().compile(pluginDir, {
|
|
69
|
-
isX: !!options.x,
|
|
70
|
-
isSingleThread: !!options.isSingleThread,
|
|
71
|
-
isPlugin: true,
|
|
72
|
-
extApis: options.extApis,
|
|
73
|
-
sourceMap: process.env.NODE_ENV === 'development',
|
|
74
|
-
});
|
|
107
|
+
return compilePlugin(pluginDir);
|
|
75
108
|
});
|
|
76
109
|
utsModuleCaches.set(pluginDir, compile);
|
|
77
110
|
const result = await compile();
|
|
@@ -87,6 +120,21 @@ function uniUTSUniModulesPlugin(options = {}) {
|
|
|
87
120
|
};
|
|
88
121
|
}
|
|
89
122
|
},
|
|
123
|
+
async generateBundle() { },
|
|
90
124
|
};
|
|
91
125
|
}
|
|
92
126
|
exports.uniUTSUniModulesPlugin = uniUTSUniModulesPlugin;
|
|
127
|
+
async function buildUniExtApiProviders() {
|
|
128
|
+
await uniExtApiCompiler();
|
|
129
|
+
}
|
|
130
|
+
exports.buildUniExtApiProviders = buildUniExtApiProviders;
|
|
131
|
+
function resolveExtApiProvider(pkg) {
|
|
132
|
+
const provider = pkg.uni_modules?.['uni-ext-api']?.provider;
|
|
133
|
+
if (provider?.service) {
|
|
134
|
+
if (provider.name && !provider.servicePlugin) {
|
|
135
|
+
provider.servicePlugin = 'uni-' + provider.service;
|
|
136
|
+
}
|
|
137
|
+
return provider;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
exports.resolveExtApiProvider = resolveExtApiProvider;
|
|
@@ -1110,6 +1110,7 @@ const preProcessors = Object.freeze({
|
|
|
1110
1110
|
function isPreProcessor(lang) {
|
|
1111
1111
|
return lang && lang in preProcessors;
|
|
1112
1112
|
}
|
|
1113
|
+
const preCssExtNames = ['.scss', '.sass', '.styl', '.stylus'];
|
|
1113
1114
|
/**
|
|
1114
1115
|
* 重写 readFileSync
|
|
1115
1116
|
* 目前主要解决 scss 文件被 @import 的条件编译
|
|
@@ -1119,8 +1120,8 @@ function rewriteScssReadFileSync() {
|
|
|
1119
1120
|
fs_1.default.readFileSync = ((filepath, options) => {
|
|
1120
1121
|
const content = readFileSync(filepath, options);
|
|
1121
1122
|
if ((0, shared_1.isString)(filepath) &&
|
|
1122
|
-
path_1.default.extname(filepath) === '.scss' &&
|
|
1123
1123
|
(0, shared_1.isString)(content) &&
|
|
1124
|
+
preCssExtNames.includes(path_1.default.extname(filepath)) &&
|
|
1124
1125
|
content.includes('#endif')) {
|
|
1125
1126
|
return (0, preprocess_1.preCss)(content);
|
|
1126
1127
|
}
|
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-4000220240228001",
|
|
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-4000220240228001",
|
|
30
|
+
"@dcloudio/uni-shared": "3.0.0-alpha-4000220240228001",
|
|
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-4000220240228001",
|
|
71
71
|
"@types/babel__code-frame": "^7.0.6",
|
|
72
72
|
"@types/babel__core": "^7.1.19",
|
|
73
73
|
"@types/debug": "^4.1.7",
|