weapp-vite 7.6.0 → 7.7.0
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/README.md +6 -4
- package/THIRD_PARTY_NOTICES.md +3 -3
- package/bin/bootstrap.js +9 -4
- package/bin/bootstrap.test.ts +82 -1
- package/bin/nodeVersionWarning.js +17 -0
- package/bin/nodeVersionWarning.test.ts +30 -0
- package/dist/{action-B3YZMA-h.mjs → action-BD56SQh4.mjs} +7 -8
- package/dist/{action-DlC6JYpt.mjs → action-CPtgEl6p.mjs} +9 -10
- package/dist/{action-BOk3vGI7.mjs → action-le0bNff_.mjs} +22 -30
- package/dist/{action-BELcDNNv.mjs → action-ytG5oFAw.mjs} +5 -6
- package/dist/{action-zEDY7oh_.mjs → action-zmJrU8PC.mjs} +11 -13
- package/dist/{analyze-DN79YOAH.mjs → analyze-DCZo-sJd.mjs} +3 -6
- package/dist/{artifacts-BOyC9Fy-.mjs → artifacts-TrTX9_jj.mjs} +2 -4
- package/dist/{assets-C5_YYXNk.mjs → assets-XyhpYtGl.mjs} +11 -18
- package/dist/auto-import-components/resolvers.d.mts +1 -1
- package/dist/auto-import-components/resolvers.mjs +1 -1
- package/dist/auto-import-presets/wevu-router.d.mts +1 -1
- package/dist/auto-import-presets/wevu-router.mjs +1 -1
- package/dist/auto-import-presets/wevu.d.mts +1 -1
- package/dist/auto-import-presets/wevu.mjs +1 -1
- package/dist/auto-import-presets.d.mts +2 -2
- package/dist/auto-import-presets.mjs +2 -2
- package/dist/auto-routes.d.mts +1 -3
- package/dist/auto-routes.mjs +3 -4
- package/dist/{budget-CTLOHwgI.d.mts → budget-DTPngJU0.d.mts} +1 -9
- package/dist/{budget-EOeEycc_.mjs → budget-_Mu-4GKn.mjs} +2 -4
- package/dist/{builtProject-C29udgXY.mjs → builtProject-B145uOt5.mjs} +11 -18
- package/dist/{classifier-DBJY__kg.mjs → classifier-CNTJOYQL.mjs} +4 -5
- package/dist/cli-acceptance.mjs +3 -4
- package/dist/cli.mjs +55 -86
- package/dist/{config-DRGcCi3h.mjs → config-59ZWhCIf.mjs} +1 -2
- package/dist/{config-Bf6DWhyb.d.mts → config-BNx2BODw.d.mts} +13 -105
- package/dist/config.d.mts +2 -2
- package/dist/config.mjs +3 -3
- package/dist/{constants-DEZdcsMn.mjs → constants-BOe8mgqL.mjs} +2 -4
- package/dist/{createCompilerContextInstance-aYwi8wQt.mjs → createCompilerContextInstance-BXSdH2E8.mjs} +1710 -1511
- package/dist/{createContext-tApLtII-.mjs → createContext-W0TeXxbo.mjs} +3 -4
- package/dist/dashboard/analyze.d.mts +1 -7
- package/dist/dashboard/analyze.mjs +2 -2
- package/dist/dashboard/vite.d.mts +2 -4
- package/dist/dashboard/vite.mjs +1 -2
- package/dist/dashboard.d.mts +2 -2
- package/dist/dashboard.mjs +20 -36
- package/dist/{dashboardTransport-C_Y6jMp-.mjs → dashboardTransport-C9290QgS.mjs} +1 -2
- package/dist/{dashboardViteBridge-DCGR43aM.mjs → dashboardViteBridge-B7QgQo94.mjs} +4 -7
- package/dist/{dev-C2fgr_Xd.mjs → dev-D1QSExwk.mjs} +2 -3
- package/dist/devProvider-Bcvz5nu4.mjs +4966 -0
- package/dist/docs/README.md +6 -4
- package/dist/docs/ai-workflows.md +2 -0
- package/dist/docs/mcp.md +1 -1
- package/dist/docs/troubleshooting.md +8 -0
- package/dist/docs/weapp-config.md +29 -0
- package/dist/docs/wevu-authoring.md +2 -0
- package/dist/doctor-worker.mjs +5 -6
- package/dist/doctor.d.mts +2 -8
- package/dist/doctor.mjs +16 -25
- package/dist/{engine-C66J0HLz.mjs → engine-Mnnm_ALP.mjs} +1 -2
- package/dist/file-5eEfbK60.mjs +1 -0
- package/dist/{file-CcIOmqhC.mjs → file-D8mp5GmB.mjs} +6 -10
- package/dist/{files-BqxFIPRp.mjs → files-Cy9jURJu.mjs} +1 -2
- package/dist/{forwardConsole-B0Reo8Lf.mjs → forwardConsole-D2Q0RIqc.mjs} +5 -7
- package/dist/getInstance-BXNVH7sU.mjs +1 -0
- package/dist/{getInstance-Dt9IQDKr.mjs → getInstance-DfNlbr-X.mjs} +2 -3
- package/dist/{history-BIiRCzbq.mjs → history-dKxzoHmN.mjs} +18 -28
- package/dist/i18n.d.mts +1 -3
- package/dist/i18n.mjs +1 -2
- package/dist/{index-D5rgBzYZ.d.mts → index-DIZJRrvK.d.mts} +1 -23
- package/dist/{index-CaXAtb9e.d.mts → index-SnaW3cvA.d.mts} +0 -12
- package/dist/index.d.mts +3 -7
- package/dist/index.mjs +6 -6
- package/dist/{json-BL8Dhhk6.mjs → json-Cvon2mw5.mjs} +1 -2
- package/dist/json.d.mts +1 -1
- package/dist/json.mjs +1 -1
- package/dist/{lib-DjccSI1B.mjs → lib-CJyMBzoe.mjs} +5 -8
- package/dist/{lifecycle-C36WSbQS.mjs → lifecycle-CUo8PMQc.mjs} +3 -6
- package/dist/{loadConfig-BWIsDXR4.mjs → loadConfig-CKIdfW4o.mjs} +2 -3
- package/dist/loadConfig-D4WGJcYp.mjs +1 -0
- package/dist/{logBuildAppFinish-ChjwATMv.mjs → logBuildAppFinish-DOBoof6S.mjs} +4 -7
- package/dist/{mcp-CYgX9HpO.mjs → mcp-D88QvQgG.mjs} +3 -5
- package/dist/{mcp-Cj8Maqo6.mjs → mcp-ovJgl1N9.mjs} +2 -4
- package/dist/mcp.d.mts +1 -3
- package/dist/mcp.mjs +1 -1
- package/dist/{mcpClient-DVLvFLZv.mjs → mcpClient-C8JzVZ46.mjs} +4 -8
- package/dist/{metadata-hwF7QRcS.mjs → metadata-HlDKtlsu.mjs} +1 -2
- package/dist/{nodeEnv-BmH8UZPR.mjs → nodeEnv-zq1EymWj.mjs} +1 -2
- package/dist/{openIde-CroqOgk5.mjs → openIde-QoYKhuuM.mjs} +8 -13
- package/dist/{options-jqFwfD1G.mjs → options-Cz8vZ-0w.mjs} +1 -2
- package/dist/{chunkStrategy-DY_LZIIe.mjs → package-DR62fAzP.mjs} +20 -31
- package/dist/{path-CYYIQGS7.mjs → path-E1OjBJAl.mjs} +1 -2
- package/dist/{platform-CnkySBKz.mjs → platform-BiMpsZIb.mjs} +1 -2
- package/dist/{pluginHost--CaeyWpA.mjs → pluginHost-vn8Vty1J.mjs} +1 -2
- package/dist/{processCleanup-BQn2kTcK.mjs → processCleanup-DzB64WI8.mjs} +1 -2
- package/dist/{protocol-Cg6Jdlvb.mjs → protocol-HiSJRrSO.mjs} +2 -3
- package/dist/{reader-sh_POQ9-.mjs → reader-wzPH_W8A.mjs} +1 -2
- package/dist/{realpathScope-Tf9mz-fh.mjs → realpathScope-DwlLaCk3.mjs} +1 -2
- package/dist/{report-hyonPGbZ.mjs → report-PJVyo-UZ.mjs} +2 -4
- package/dist/{resolvedId-CiDl7SC1.mjs → resolvedId-DaxPh_yV.mjs} +2 -4
- package/dist/{resolvers-Dod-euqX.mjs → resolvers-CKYqmRD_.mjs} +10 -20
- package/dist/resolvers.d.mts +1 -1
- package/dist/resolvers.mjs +1 -1
- package/dist/{routes-C7fCmf92.d.mts → routes-DvAFX29h.d.mts} +0 -2
- package/dist/{runtime-DpVf714f.d.mts → runtime-BL4RjBRa.d.mts} +0 -8
- package/dist/{runtime-CLUhQsdA.mjs → runtime-CKtMVERT.mjs} +2 -3
- package/dist/{runtime-D6VCNhNY.mjs → runtime-DDUCb7pP.mjs} +4 -8
- package/dist/runtime.d.mts +1 -1
- package/dist/runtime.mjs +1 -1
- package/dist/{schematics-kO26eQRT.mjs → schematics-DikfOjMD.mjs} +1 -2
- package/dist/{session-D3zsdzIy.mjs → session-COrQJYif.mjs} +16 -18
- package/dist/test.d.mts +1 -3
- package/dist/test.mjs +50 -28
- package/dist/{types-D0FFexRF.d.mts → types-BK2EQ3Jm.d.mts} +0 -2
- package/dist/{types-D-kfuyVa.d.mts → types-e2BMP9NU.d.mts} +0 -2
- package/dist/types.d.mts +4 -4
- package/dist/{upload-DozK8UdN.mjs → upload-Chal5b3w.mjs} +11 -21
- package/dist/upload-worker.mjs +3 -5
- package/dist/{utils-Dy51PYAC.mjs → utils-CTGSZp4j.mjs} +20 -34
- package/dist/vite.d.mts +2 -4
- package/dist/vite.mjs +9 -14
- package/dist/volar.mjs +1 -2
- package/dist/{wevu-BQWUU7br.mjs → wevu-BaihCXO9.mjs} +1 -2
- package/dist/wevu-DTtSOyxB.d.mts +3 -0
- package/dist/{wevu-router-Dg1LnBlg.mjs → wevu-router-BIoxDbnu.mjs} +1 -2
- package/dist/wevu-router-CdWurGQ4.d.mts +3 -0
- package/dist/wxs-7V7MPzeW.mjs +1 -0
- package/dist/{wxs-BT8btflA.mjs → wxs-BdHHXltv.mjs} +2 -4
- package/package.json +46 -43
- package/dist/devProvider-D-hTfsEO.mjs +0 -3027
- package/dist/file-DtcteQ4G.mjs +0 -1
- package/dist/getInstance-BAIaU2y9.mjs +0 -1
- package/dist/loadConfig-D-BpBgsk.mjs +0 -1
- package/dist/package-Cmakyy3J.mjs +0 -4
- package/dist/wevu-C4KEC5kO.d.mts +0 -5
- package/dist/wevu-router-Cg2sIkIE.d.mts +0 -5
- package/dist/wxs-Z4VQDeJ_.mjs +0 -1
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { d as ResolvedValue, f as Resolver } from "./index-
|
|
2
|
-
import { t as AutoRoutes } from "./routes-
|
|
3
|
-
import { t as WeappI18nConfig } from "./types-
|
|
4
|
-
import { r as GlassEaselTemplateFinding, t as GlassEaselAnalysisFact } from "./types-
|
|
1
|
+
import { d as ResolvedValue, f as Resolver } from "./index-SnaW3cvA.mjs";
|
|
2
|
+
import { t as AutoRoutes } from "./routes-DvAFX29h.mjs";
|
|
3
|
+
import { t as WeappI18nConfig } from "./types-e2BMP9NU.mjs";
|
|
4
|
+
import { r as GlassEaselTemplateFinding, t as GlassEaselAnalysisFact } from "./types-BK2EQ3Jm.mjs";
|
|
5
|
+
import { WebRuntimeGlobalTarget } from "@weapp-core/constants";
|
|
5
6
|
import { MpPlatform, OutputExtensions } from "@weapp-core/shared";
|
|
6
7
|
import { WeappAstConfig } from "@weapp-vite/ast";
|
|
7
8
|
import "@weapp-vite/ast/operations/onPageScroll";
|
|
@@ -18,6 +19,7 @@ import "get-tsconfig";
|
|
|
18
19
|
import { WrapPluginOptions } from "vite-plugin-performance";
|
|
19
20
|
import { Options } from "rolldown-plugin-dts";
|
|
20
21
|
import { App, App as App$1, Component, Component as Component$1, GenerateType, Page, Page as Page$1, Plugin as Plugin$1, Sitemap, Sitemap as Sitemap$1, Theme, Theme as Theme$1 } from "@weapp-core/schematics";
|
|
22
|
+
import { ChokidarOptions } from "chokidar";
|
|
21
23
|
import { InputOption, OutputBundle, OutputChunk, ResolvedId, RolldownBuild, RolldownOptions, RolldownOutput, RolldownOutput as RolldownOutput$1, RolldownPlugin, RolldownPluginOption, RolldownWatcher, RolldownWatcher as RolldownWatcher$1, WatchOptions as RolldownWatchOptions } from "rolldown";
|
|
22
24
|
import { MiniProgramNetworkDefaults } from "@wevu/web-apis/network-defaults";
|
|
23
25
|
import { PageLayoutMeta, WevuConfigDefaults } from "wevu/config";
|
|
@@ -27,7 +29,6 @@ import { CreateCompilerOptions } from "weapp-tailwindcss/core";
|
|
|
27
29
|
import { UserDefinedOptions } from "weapp-tailwindcss/types";
|
|
28
30
|
import { ComputedDefinitions as ComputedDefinitions$1, MethodDefinitions as MethodDefinitions$1, Ref } from "wevu/types";
|
|
29
31
|
import { DetectResult } from "package-manager-detector";
|
|
30
|
-
//#region src/runtimeTarget.d.ts
|
|
31
32
|
type WebPlatform = 'web';
|
|
32
33
|
type WeappViteRuntime = 'miniprogram' | 'web';
|
|
33
34
|
type WeappVitePlatform = MpPlatform$1 | WebPlatform;
|
|
@@ -56,8 +57,6 @@ declare function isWebPlatform(input?: string | null): boolean;
|
|
|
56
57
|
declare function getSupportedWeappViteTargetDescriptors(): readonly WeappViteTargetDescriptor[];
|
|
57
58
|
declare function getSupportedWeappVitePlatforms(): readonly WeappVitePlatform[];
|
|
58
59
|
declare function resolveWeappViteTarget(input?: WeappViteTargetInput | null, options?: ResolveWeappViteTargetOptions): ResolvedWeappViteTarget;
|
|
59
|
-
//#endregion
|
|
60
|
-
//#region src/pluginHost.d.ts
|
|
61
60
|
declare const WEAPP_VITE_HOST_NAME = "weapp-vite";
|
|
62
61
|
interface WeappViteHostMeta {
|
|
63
62
|
name: typeof WEAPP_VITE_HOST_NAME;
|
|
@@ -76,15 +75,11 @@ declare module 'vite' {
|
|
|
76
75
|
weappVite?: WeappViteHostMeta;
|
|
77
76
|
}
|
|
78
77
|
}
|
|
79
|
-
//#endregion
|
|
80
|
-
//#region src/utils/importMeta.d.ts
|
|
81
78
|
interface ImportMetaDefineRegistry {
|
|
82
79
|
defineEntries: Record<string, any>;
|
|
83
80
|
envObject: Record<string, any>;
|
|
84
81
|
envMemberAccess: Record<string, any>;
|
|
85
82
|
}
|
|
86
|
-
//#endregion
|
|
87
|
-
//#region src/types/config/foundation.d.ts
|
|
88
83
|
type NpmBuildOptions = InlineConfig;
|
|
89
84
|
type MpPlatform$1 = MpPlatform;
|
|
90
85
|
/**
|
|
@@ -354,8 +349,6 @@ interface ChunksConfig {
|
|
|
354
349
|
forceDuplicatePatterns?: (string | RegExp)[];
|
|
355
350
|
duplicateWarningBytes?: number;
|
|
356
351
|
}
|
|
357
|
-
//#endregion
|
|
358
|
-
//#region src/types/config/projectConfig.d.ts
|
|
359
352
|
/** 保留原生工具新增字段,已声明字段仍提供类型检查与补全。 */
|
|
360
353
|
interface NativeOptions {
|
|
361
354
|
[key: string]: unknown;
|
|
@@ -512,8 +505,6 @@ interface MultiPlatformProjectConfigs {
|
|
|
512
505
|
/** 百度:生成 `project.swan.json`。 */
|
|
513
506
|
swan?: SwanProjectConfig;
|
|
514
507
|
}
|
|
515
|
-
//#endregion
|
|
516
|
-
//#region src/types/config/wxmlTransform.d.ts
|
|
517
508
|
/** 模板属性的新值;字符串为字面量,表达式只生成绑定而不在构建端求值。 */
|
|
518
509
|
type WxmlAttributeValue = string | number | boolean | {
|
|
519
510
|
expression: string;
|
|
@@ -571,8 +562,6 @@ interface WxmlTransformContext {
|
|
|
571
562
|
error: (message: string) => never;
|
|
572
563
|
}
|
|
573
564
|
type WxmlTransform = (code: string, context: WxmlTransformContext) => WxmlTransformResult | Promise<WxmlTransformResult>;
|
|
574
|
-
//#endregion
|
|
575
|
-
//#region src/types/config/wxmlValidate.d.ts
|
|
576
565
|
/** 诊断位置对应最终输出模板;不映射回 Vue 等源文件。 */
|
|
577
566
|
interface WxmlValidationDiagnostic {
|
|
578
567
|
severity: 'warning' | 'error';
|
|
@@ -589,8 +578,6 @@ interface WxmlValidationContext extends Pick<WxmlTransformContext, 'fileName' |
|
|
|
589
578
|
}
|
|
590
579
|
/** 返回值不用于转换;非 undefined 返回值会作为配置错误报告。 */
|
|
591
580
|
type WxmlValidate = (code: string, context: WxmlValidationContext) => void | Promise<void>;
|
|
592
|
-
//#endregion
|
|
593
|
-
//#region src/types/config/features.d.ts
|
|
594
581
|
/**
|
|
595
582
|
* @description 自动导入组件配置
|
|
596
583
|
*/
|
|
@@ -766,7 +753,7 @@ interface WeappInjectWeapiConfig {
|
|
|
766
753
|
replaceWx?: boolean;
|
|
767
754
|
globalName?: string;
|
|
768
755
|
}
|
|
769
|
-
type WeappInjectWebRuntimeGlobalsTarget =
|
|
756
|
+
type WeappInjectWebRuntimeGlobalsTarget = WebRuntimeGlobalTarget;
|
|
770
757
|
type WeappInjectRequestGlobalsTarget = WeappInjectWebRuntimeGlobalsTarget;
|
|
771
758
|
/**
|
|
772
759
|
* @description Web Runtime 全局对象注入配置
|
|
@@ -945,8 +932,6 @@ interface WeappRouteRule {
|
|
|
945
932
|
preload?: WeappPreloadRule;
|
|
946
933
|
}
|
|
947
934
|
type WeappRouteRules = Record<string, WeappRouteRule>;
|
|
948
|
-
//#endregion
|
|
949
|
-
//#region ../../node_modules/.pnpm/vite-tsconfig-paths@7.0.0-alpha.3_supports-color@10.2.2_vite@8.3.4/node_modules/vite-tsconfig-paths/dist/types.d.ts
|
|
950
935
|
interface PluginOptions {
|
|
951
936
|
/**
|
|
952
937
|
* The directory to crawl for `tsconfig.json` files.
|
|
@@ -1036,15 +1021,11 @@ interface PluginOptions {
|
|
|
1036
1021
|
*/
|
|
1037
1022
|
logFile?: string | boolean;
|
|
1038
1023
|
}
|
|
1039
|
-
//#endregion
|
|
1040
|
-
//#region src/types/config/tsconfigPaths.d.ts
|
|
1041
1024
|
/** 高级路径适配选项,保留旧配置的类型兼容。 */
|
|
1042
1025
|
interface TsconfigPathsOptions extends PluginOptions {
|
|
1043
1026
|
/** @deprecated 解析器已统一处理继承和路径,此选项仅兼容旧配置,不再加载 TypeScript 编译器。 */
|
|
1044
1027
|
parseNative?: boolean;
|
|
1045
1028
|
}
|
|
1046
|
-
//#endregion
|
|
1047
|
-
//#region src/types/config/main.d.ts
|
|
1048
1029
|
type WeappTailwindcssOptions = UserDefinedOptions & Pick<CreateCompilerOptions, 'compiler'>;
|
|
1049
1030
|
/**
|
|
1050
1031
|
* @description 分包元信息
|
|
@@ -1295,8 +1276,6 @@ interface ProjectConfig {
|
|
|
1295
1276
|
}[];
|
|
1296
1277
|
};
|
|
1297
1278
|
}
|
|
1298
|
-
//#endregion
|
|
1299
|
-
//#region src/types/compilerPlugin.d.ts
|
|
1300
1279
|
type WeappCompilerPluginPhase = 'source' | 'output';
|
|
1301
1280
|
type WeappCompilerResourceKind = 'style' | 'template' | 'script';
|
|
1302
1281
|
interface WeappCompilerPluginCapabilities {
|
|
@@ -1381,8 +1360,6 @@ interface WeappCompilerPlugin {
|
|
|
1381
1360
|
}
|
|
1382
1361
|
type WeappCompilerPluginFactory = (context: WeappCompilerPluginContext) => WeappCompilerPlugin | Promise<WeappCompilerPlugin>;
|
|
1383
1362
|
type WeappCompilerPluginOption = WeappCompilerPlugin | WeappCompilerPluginFactory;
|
|
1384
|
-
//#endregion
|
|
1385
|
-
//#region src/types/context.d.ts
|
|
1386
1363
|
interface WxmlDep {
|
|
1387
1364
|
tagName: string;
|
|
1388
1365
|
start: number;
|
|
@@ -1397,8 +1374,6 @@ interface ScanComponentItem {
|
|
|
1397
1374
|
end: number;
|
|
1398
1375
|
}
|
|
1399
1376
|
type ComponentsMap = Record<string, ScanComponentItem[]>;
|
|
1400
|
-
//#endregion
|
|
1401
|
-
//#region src/types/entry.d.ts
|
|
1402
1377
|
interface BaseEntry {
|
|
1403
1378
|
path: string;
|
|
1404
1379
|
jsonPath?: string;
|
|
@@ -1439,8 +1414,6 @@ interface ComponentEntry extends BaseEntry {
|
|
|
1439
1414
|
jsonPath: string;
|
|
1440
1415
|
}
|
|
1441
1416
|
type EntryJsonFragment = Omit<BaseEntry, 'path' | 'type'>;
|
|
1442
|
-
//#endregion
|
|
1443
|
-
//#region src/types/errors.d.ts
|
|
1444
1417
|
interface BindingErrorLike {
|
|
1445
1418
|
message?: string;
|
|
1446
1419
|
code?: string;
|
|
@@ -1449,11 +1422,7 @@ interface BindingErrorLike {
|
|
|
1449
1422
|
frame?: string;
|
|
1450
1423
|
stack?: string;
|
|
1451
1424
|
}
|
|
1452
|
-
//#endregion
|
|
1453
|
-
//#region src/moduleGraph/protocol.d.ts
|
|
1454
1425
|
type SidecarModuleKind = 'json' | 'jsx' | 'layout' | 'script' | 'style' | 'template' | 'using-component' | 'wxs';
|
|
1455
|
-
//#endregion
|
|
1456
|
-
//#region src/moduleGraph/types.d.ts
|
|
1457
1426
|
interface BuildModuleInfo {
|
|
1458
1427
|
dynamicImporters?: readonly string[];
|
|
1459
1428
|
exports?: readonly string[];
|
|
@@ -1506,8 +1475,6 @@ interface TopologyRescanRequest {
|
|
|
1506
1475
|
files: Set<string>;
|
|
1507
1476
|
reasons: Set<string>;
|
|
1508
1477
|
}
|
|
1509
|
-
//#endregion
|
|
1510
|
-
//#region src/moduleGraph/service.d.ts
|
|
1511
1478
|
interface ModuleGraphService {
|
|
1512
1479
|
/** 只替换指定 scope;返回仅对应本次绑定的释放器。 */
|
|
1513
1480
|
bindBuildContext: (scope: object, context: BuildGraphContext) => () => void;
|
|
@@ -1553,8 +1520,6 @@ interface ModuleGraphService {
|
|
|
1553
1520
|
sourceId: string;
|
|
1554
1521
|
}>;
|
|
1555
1522
|
}
|
|
1556
|
-
//#endregion
|
|
1557
|
-
//#region src/runtime/buildPlugin/service.d.ts
|
|
1558
1523
|
interface BuildOptions {
|
|
1559
1524
|
skipNpm?: boolean;
|
|
1560
1525
|
}
|
|
@@ -1566,8 +1531,6 @@ interface BuildService {
|
|
|
1566
1531
|
getIndependentOutput: (root: string) => RolldownOutput | undefined;
|
|
1567
1532
|
invalidateIndependentOutput: (root: string) => void;
|
|
1568
1533
|
}
|
|
1569
|
-
//#endregion
|
|
1570
|
-
//#region ../../node_modules/.pnpm/pkg-types@2.3.3/node_modules/pkg-types/dist/index.d.mts
|
|
1571
1534
|
interface PackageJson {
|
|
1572
1535
|
/**
|
|
1573
1536
|
* The name is what your thing is called.
|
|
@@ -1862,26 +1825,18 @@ type PackageJsonFunding = string | {
|
|
|
1862
1825
|
type PackageJsonExportKey = "." | "import" | "require" | "types" | "node" | "browser" | "default" | (string & {});
|
|
1863
1826
|
type PackageJsonExportsObject = { [P in PackageJsonExportKey]?: string | PackageJsonExportsObject | Array<string | PackageJsonExportsObject>; };
|
|
1864
1827
|
type PackageJsonExports = string | PackageJsonExportsObject | Array<string | PackageJsonExportsObject>;
|
|
1865
|
-
//#endregion
|
|
1866
|
-
//#region src/multiPlatform.d.ts
|
|
1867
1828
|
interface ResolvedMultiPlatformConfig {
|
|
1868
1829
|
enabled: boolean;
|
|
1869
1830
|
projectConfigRoot: string;
|
|
1870
1831
|
targets: readonly MpPlatform$1[];
|
|
1871
1832
|
projectConfigs?: MultiPlatformProjectConfigs;
|
|
1872
1833
|
}
|
|
1873
|
-
//#endregion
|
|
1874
|
-
//#region src/utils/json.d.ts
|
|
1875
1834
|
interface JsonResolvableEntry {
|
|
1876
1835
|
json?: any;
|
|
1877
1836
|
jsonPath?: string;
|
|
1878
1837
|
type?: 'app' | 'page' | 'component' | 'plugin';
|
|
1879
1838
|
}
|
|
1880
|
-
//#endregion
|
|
1881
|
-
//#region src/utils/loadViteConfigFile.d.ts
|
|
1882
1839
|
type ViteConfigLoader = 'bundle' | 'runner' | 'native';
|
|
1883
|
-
//#endregion
|
|
1884
|
-
//#region src/runtime/config/types.d.ts
|
|
1885
1840
|
interface LoadConfigOptions {
|
|
1886
1841
|
cwd: string;
|
|
1887
1842
|
isDev: boolean;
|
|
@@ -2018,8 +1973,6 @@ interface ResolvedWeappWebConfig {
|
|
|
2018
1973
|
userConfig?: InlineConfig;
|
|
2019
1974
|
source?: WeappWebConfig;
|
|
2020
1975
|
}
|
|
2021
|
-
//#endregion
|
|
2022
|
-
//#region src/cache/file.d.ts
|
|
2023
1976
|
type HashInput = string | Buffer;
|
|
2024
1977
|
declare class FileCache<T extends object> {
|
|
2025
1978
|
cache: LRUCache<string, T>;
|
|
@@ -2036,15 +1989,11 @@ declare class FileCache<T extends object> {
|
|
|
2036
1989
|
signature?: string;
|
|
2037
1990
|
}): Promise<boolean>;
|
|
2038
1991
|
}
|
|
2039
|
-
//#endregion
|
|
2040
|
-
//#region src/runtime/jsonPlugin.d.ts
|
|
2041
1992
|
interface JsonService {
|
|
2042
1993
|
read: (filepath: string) => Promise<any>;
|
|
2043
1994
|
resolve: (entry: JsonResolvableEntry) => string | undefined;
|
|
2044
1995
|
cache: FileCache<any>;
|
|
2045
1996
|
}
|
|
2046
|
-
//#endregion
|
|
2047
|
-
//#region src/runtime/npmPlugin/builder/packageBuilder.d.ts
|
|
2048
1997
|
interface PackageBuilder {
|
|
2049
1998
|
isMiniprogramPackage: (pkg: PackageJson) => boolean;
|
|
2050
1999
|
shouldSkipBuild: (outDir: string, isOutdated: boolean) => Promise<boolean>;
|
|
@@ -2068,8 +2017,6 @@ interface BuildPackageArgs {
|
|
|
2068
2017
|
options?: NpmBuildOptions;
|
|
2069
2018
|
isDependenciesCacheOutdate: boolean;
|
|
2070
2019
|
}
|
|
2071
|
-
//#endregion
|
|
2072
|
-
//#region src/runtime/npmPlugin/service/types.d.ts
|
|
2073
2020
|
interface NpmService {
|
|
2074
2021
|
getDependenciesCacheFilePath: (key?: string) => string;
|
|
2075
2022
|
readonly dependenciesCacheHash: string;
|
|
@@ -2096,8 +2043,6 @@ interface NpmService {
|
|
|
2096
2043
|
}[];
|
|
2097
2044
|
build: (options?: NpmBuildOptions) => Promise<void>;
|
|
2098
2045
|
}
|
|
2099
|
-
//#endregion
|
|
2100
|
-
//#region src/utils/hmrProfile/provenance.d.ts
|
|
2101
2046
|
interface HmrProfileSourceEvent {
|
|
2102
2047
|
eventId: string;
|
|
2103
2048
|
event?: ChangeEvent;
|
|
@@ -2111,15 +2056,11 @@ interface HmrProfileProvenance {
|
|
|
2111
2056
|
batchWaitMs?: number;
|
|
2112
2057
|
queueWaitMs?: number;
|
|
2113
2058
|
}
|
|
2114
|
-
//#endregion
|
|
2115
|
-
//#region src/wxml/shared.d.ts
|
|
2116
2059
|
interface Token {
|
|
2117
2060
|
start: number;
|
|
2118
2061
|
end: number;
|
|
2119
2062
|
value: string;
|
|
2120
2063
|
}
|
|
2121
|
-
//#endregion
|
|
2122
|
-
//#region src/wxml/scan/types.d.ts
|
|
2123
2064
|
interface RemovalRange {
|
|
2124
2065
|
start: number;
|
|
2125
2066
|
end: number;
|
|
@@ -2156,12 +2097,8 @@ interface WxmlToken {
|
|
|
2156
2097
|
glassEaselFindings?: GlassEaselTemplateFinding[];
|
|
2157
2098
|
code: string;
|
|
2158
2099
|
}
|
|
2159
|
-
//#endregion
|
|
2160
|
-
//#region src/wxml/scan/index.d.ts
|
|
2161
2100
|
declare function scanWxml(wxml: string | Buffer, options?: ScanWxmlOptions): WxmlToken;
|
|
2162
2101
|
type ScanWxmlResult = ReturnType<typeof scanWxml>;
|
|
2163
|
-
//#endregion
|
|
2164
|
-
//#region src/wxml/processing/registry.d.ts
|
|
2165
2102
|
type TemplateDependencies = Map<string, Set<string>>;
|
|
2166
2103
|
type ProcessingStage = 'transform' | 'validate';
|
|
2167
2104
|
interface WxmlDependencyRegistry {
|
|
@@ -2175,30 +2112,22 @@ interface WxmlDependencyRegistry {
|
|
|
2175
2112
|
references: Map<string, number>;
|
|
2176
2113
|
listeners: Set<(files: string[]) => void>;
|
|
2177
2114
|
}
|
|
2178
|
-
//#endregion
|
|
2179
|
-
//#region src/runtime/autoImport/types.d.ts
|
|
2180
2115
|
interface LocalAutoImportMatch {
|
|
2181
2116
|
kind: 'local';
|
|
2182
2117
|
entry: ComponentEntry;
|
|
2183
2118
|
value: ResolvedValue;
|
|
2184
2119
|
}
|
|
2185
|
-
//#endregion
|
|
2186
|
-
//#region src/runtime/autoRoutesPlugin/types.d.ts
|
|
2187
2120
|
interface NamedAutoRoute {
|
|
2188
2121
|
name: string;
|
|
2189
2122
|
path: string;
|
|
2190
2123
|
meta: Record<string, StaticRouteValue>;
|
|
2191
2124
|
}
|
|
2192
|
-
//#endregion
|
|
2193
|
-
//#region src/runtime/watcher/types.d.ts
|
|
2194
2125
|
interface WatcherInstance {
|
|
2195
2126
|
close: () => void | Promise<void>;
|
|
2196
2127
|
}
|
|
2197
2128
|
interface SidecarWatcher {
|
|
2198
2129
|
close: () => void | Promise<void>;
|
|
2199
2130
|
}
|
|
2200
|
-
//#endregion
|
|
2201
|
-
//#region src/runtime/runtimeState.d.ts
|
|
2202
2131
|
interface AutoRoutesCandidateState {
|
|
2203
2132
|
base: string;
|
|
2204
2133
|
files: Set<string>;
|
|
@@ -2518,8 +2447,6 @@ interface RuntimeState {
|
|
|
2518
2447
|
options: LoadConfigResult;
|
|
2519
2448
|
};
|
|
2520
2449
|
}
|
|
2521
|
-
//#endregion
|
|
2522
|
-
//#region src/runtime/scanPlugin/service/index.d.ts
|
|
2523
2450
|
interface ScanService {
|
|
2524
2451
|
appEntry?: AppEntry;
|
|
2525
2452
|
pluginJson?: Plugin$1;
|
|
@@ -2536,8 +2463,6 @@ interface ScanService {
|
|
|
2536
2463
|
markIndependentDirty: (root: string) => void;
|
|
2537
2464
|
drainIndependentDirtyRoots: () => string[];
|
|
2538
2465
|
}
|
|
2539
|
-
//#endregion
|
|
2540
|
-
//#region src/runtime/watcherPlugin.d.ts
|
|
2541
2466
|
interface WatcherService {
|
|
2542
2467
|
rollupWatcherMap: Map<string, WatcherInstance>;
|
|
2543
2468
|
sidecarWatcherMap: Map<string, SidecarWatcher>;
|
|
@@ -2546,8 +2471,6 @@ interface WatcherService {
|
|
|
2546
2471
|
close: (root?: string) => void;
|
|
2547
2472
|
closeAll: () => void | Promise<void>;
|
|
2548
2473
|
}
|
|
2549
|
-
//#endregion
|
|
2550
|
-
//#region src/runtime/webPlugin.d.ts
|
|
2551
2474
|
interface WebService {
|
|
2552
2475
|
readonly devServer?: ViteDevServer;
|
|
2553
2476
|
isEnabled: () => boolean;
|
|
@@ -2555,12 +2478,8 @@ interface WebService {
|
|
|
2555
2478
|
build: () => Promise<Awaited<ReturnType<typeof build>> | undefined>;
|
|
2556
2479
|
close: () => Promise<void>;
|
|
2557
2480
|
}
|
|
2558
|
-
//#endregion
|
|
2559
|
-
//#region src/runtime/wxmlPlugin/service/shared.d.ts
|
|
2560
2481
|
type WxmlDependencyKind = 'template-import' | 'template-include' | 'script-module' | 'unknown';
|
|
2561
2482
|
type WxmlImporterDependencyKind = WxmlDependencyKind | 'mixed';
|
|
2562
|
-
//#endregion
|
|
2563
|
-
//#region src/runtime/wxmlPlugin/types.d.ts
|
|
2564
2483
|
interface WxmlService {
|
|
2565
2484
|
depsMap: Map<string, Set<string>>;
|
|
2566
2485
|
importerMap: Map<string, Set<string>>;
|
|
@@ -2592,8 +2511,6 @@ interface WxmlService {
|
|
|
2592
2511
|
scan: (filepath: string) => Promise<ScanWxmlResult | undefined>;
|
|
2593
2512
|
setWxmlComponentsMap: (absPath: string, components: ComponentsMap) => void;
|
|
2594
2513
|
}
|
|
2595
|
-
//#endregion
|
|
2596
|
-
//#region src/runtime/autoImport/service/types.d.ts
|
|
2597
2514
|
interface ResolverAutoImportMatch {
|
|
2598
2515
|
kind: 'resolver';
|
|
2599
2516
|
value: ResolvedValue;
|
|
@@ -2617,16 +2534,10 @@ interface AutoImportService {
|
|
|
2617
2534
|
awaitPendingRegistrations?: () => Promise<void>;
|
|
2618
2535
|
awaitManifestWrites: () => Promise<void>;
|
|
2619
2536
|
}
|
|
2620
|
-
//#endregion
|
|
2621
|
-
//#region src/runtime/autoRoutesPlugin/routes/scan.d.ts
|
|
2622
2537
|
interface ScanRoutesOptions {
|
|
2623
2538
|
resolvePageDeclarationSource?: ResolveSfcBlockSrcOptions['resolveId'];
|
|
2624
2539
|
}
|
|
2625
|
-
//#endregion
|
|
2626
|
-
//#region src/runtime/autoRoutesPlugin/watch.d.ts
|
|
2627
2540
|
type AutoRoutesFileEvent = ChangeEvent | 'rename';
|
|
2628
|
-
//#endregion
|
|
2629
|
-
//#region src/runtime/autoRoutesPlugin/service.d.ts
|
|
2630
2541
|
type PageDeclarationSourceResolver = NonNullable<ScanRoutesOptions['resolvePageDeclarationSource']>;
|
|
2631
2542
|
interface AutoRoutesService {
|
|
2632
2543
|
/** 活动构建解析器只参与本次刷新,不替换服务持有的长期解析器。 */
|
|
@@ -2653,8 +2564,6 @@ interface AutoRoutesService {
|
|
|
2653
2564
|
isInitialized: () => boolean;
|
|
2654
2565
|
isEnabled: () => boolean;
|
|
2655
2566
|
}
|
|
2656
|
-
//#endregion
|
|
2657
|
-
//#region src/context/CompilerContext.d.ts
|
|
2658
2567
|
type BuildTarget = 'app' | 'plugin';
|
|
2659
2568
|
interface CompilerContext {
|
|
2660
2569
|
runtimeState: RuntimeState;
|
|
@@ -2672,14 +2581,10 @@ interface CompilerContext {
|
|
|
2672
2581
|
currentBuildTarget?: BuildTarget;
|
|
2673
2582
|
onStatefulHmrSourceChange?: (file: string, dirtyReasonSummary: string[], sourceEvent?: HmrProfileSourceEvent) => void;
|
|
2674
2583
|
}
|
|
2675
|
-
//#endregion
|
|
2676
|
-
//#region src/types/plugin.d.ts
|
|
2677
2584
|
interface WeappVitePluginApi {
|
|
2678
2585
|
ctx: CompilerContext;
|
|
2679
2586
|
}
|
|
2680
2587
|
type ChangeEvent = 'create' | 'update' | 'delete';
|
|
2681
|
-
//#endregion
|
|
2682
|
-
//#region src/json.d.ts
|
|
2683
2588
|
type ReturnSelf<T> = (config: T) => T;
|
|
2684
2589
|
type ConfigFn<T> = T | ((ctx: CompilerContext) => T);
|
|
2685
2590
|
type DefineJsonFn<T> = ReturnSelf<ConfigFn<T>>;
|
|
@@ -2703,8 +2608,6 @@ declare const defineSitemapJson: DefineJsonFn<Sitemap$1>;
|
|
|
2703
2608
|
* @description 定义 theme.json(支持直接对象或函数形式)
|
|
2704
2609
|
*/
|
|
2705
2610
|
declare const defineThemeJson: DefineJsonFn<Theme$1>;
|
|
2706
|
-
//#endregion
|
|
2707
|
-
//#region src/config.d.ts
|
|
2708
2611
|
/**
|
|
2709
2612
|
* @description weapp-vite 的用户配置(扩展 Vite UserConfig)
|
|
2710
2613
|
*/
|
|
@@ -2718,6 +2621,12 @@ type UserConfigFnObject<T extends UserConfig$1 = UserConfig$1> = (env: ConfigEnv
|
|
|
2718
2621
|
type UserConfigFnPromise<T extends UserConfig$1 = UserConfig$1> = (env: ConfigEnv) => Promise<T>;
|
|
2719
2622
|
type UserConfigFn<T extends UserConfig$1 = UserConfig$1> = (env: ConfigEnv) => T | Promise<T>;
|
|
2720
2623
|
type UserConfigExport<T extends UserConfig$1 = UserConfig$1> = T | Promise<T> | UserConfigFnObject<T> | UserConfigFnPromise<T> | UserConfigFn<T>;
|
|
2624
|
+
declare module 'rolldown' {
|
|
2625
|
+
interface WatcherOptions {
|
|
2626
|
+
/** weapp-vite 自有 sidecar watcher 的 backend 与轮询选项。 */
|
|
2627
|
+
chokidar?: Pick<ChokidarOptions, 'backend' | 'pollingInterval' | 'pollingBinaryInterval' | 'usePolling' | 'interval' | 'binaryInterval'>;
|
|
2628
|
+
}
|
|
2629
|
+
}
|
|
2721
2630
|
declare module 'vite' {
|
|
2722
2631
|
interface UserConfig {
|
|
2723
2632
|
weapp?: WeappViteConfig;
|
|
@@ -2730,5 +2639,4 @@ declare module 'vite' {
|
|
|
2730
2639
|
* @description 导致 `platform` 等联合字面量字段被宽化为 `string`。
|
|
2731
2640
|
*/
|
|
2732
2641
|
declare function defineConfig<T extends UserConfigExport>(config: T): T;
|
|
2733
|
-
//#endregion
|
|
2734
2642
|
export { WeappCompilerOutputRequest as $, NpmPackageFilesConfig as $n, WeappUniAppConfig as $t, Ref as A, GenerateDirsOptions as An, WEAPP_VITE_HOST_NAME as Ar, WeappAppPreludeConfig as At, BindingErrorLike as B, GenerateTemplateInlineSource as Bn, WeappViteRuntime as Br, WeappInjectWeapiConfig as Bt, LoadConfigOptions as C, AliasOptions as Cn, WeappLibVueTscOptions as Cr, AutoImportComponents as Ct, MethodDefinitions$1 as D, CopyGlobs as Dn, WeappManagedSharedTsconfigConfig as Dr, HandleWxmlOptions as Dt, InlineConfig$1 as E, ChunksConfig as En, WeappManagedServerTsconfigConfig as Er, EnhanceWxmlOptions as Et, RolldownPlugin as F, GenerateTemplate as Fn, resolveWeappViteHostMeta as Fr, WeappBuildScopeConfig as Ft, EntryJsonFragment as G, JsonMergeContext as Gn, getSupportedWeappVitePlatforms as Gr, WeappPreloadNetwork as Gt, BaseEntry as H, GenerateTemplatesConfig as Hn, WeappViteTargetInput as Hr, WeappInjectWebRuntimeGlobalsTarget as Ht, RolldownPluginOption as I, GenerateTemplateContext as In, ResolveWeappViteTargetOptions as Ir, WeappBuildScopeObjectConfig as It, ScanComponentItem as J, JsonMergeStrategy as Jn, resolveWeappViteTarget as Jr, WeappReactConfig as Jt, PageEntry as K, JsonMergeFunction as Kn, getSupportedWeappViteTargetDescriptors as Kr, WeappPreloadRule as Kt, RolldownWatchOptions as L, GenerateTemplateEntry as Ln, ResolvedWeappViteTarget as Lr, WeappHmrConfig as Lt, RolldownBuild as M, GenerateFileType as Mn, applyWeappViteHostMeta as Mr, WeappAutoRoutesConfig as Mt, RolldownOptions as N, GenerateFilenamesOptions as Nn, createWeappViteHostMeta as Nr, WeappAutoRoutesInclude as Nt, Plugin$2 as O, CopyOptions as On, WeappManagedTypeScriptConfig as Or, MultiPlatformConfig as Ot, RolldownOutput$1 as P, GenerateOptions as Pn, isWeappViteHost as Pr, WeappAutoRoutesIncludePattern as Pt, WeappCompilerHmrRequest as Q, NpmMainPackageConfig as Qn, WeappSubPackageConfig as Qt, RolldownWatcher$1 as R, GenerateTemplateFactory as Rn, WEB_PLATFORM_ALIASES as Rr, WeappInjectRequestGlobalsConfig as Rt, CompilerContext as S, Alias as Sn, WeappLibInternalDtsOptions as Sr, WeappViteConfig as St, ConfigEnv$1 as T, BuildNpmPackageMeta as Tn, WeappManagedNodeTsconfigConfig as Tr, EnhanceOptions as Tt, ComponentEntry as U, JsFormat as Un, WeappViteTargetKind as Ur, WeappMcpConfig as Ut, AppEntry as V, GenerateTemplateScope as Vn, WeappViteTargetDescriptor as Vr, WeappInjectWebRuntimeGlobalsConfig as Vt, Entry as W, JsonConfig as Wn, WebPlatform as Wr, WeappNpmConfig as Wt, WeappCompilerHmrAsset as X, NpmBuildOptions as Xn, WeappRouteRule as Xt, WxmlDep as Y, MpPlatform$1 as Yn, WeappRequestRuntimeConfig as Yt, WeappCompilerHmrPreparation as Z, NpmDependencyPattern as Zn, WeappRouteRules as Zt, definePageJson as _, WxmlTransformNode as _n, WeappLibComponentJson as _r, WeappDebugConfig as _t, UserConfigFnNoEnvPlain as a, WxmlRemoveAttrRule as an, SharedChunkMode as ar, WeappCompilerPluginOption as at, ChangeEvent as b, MultiPlatformProjectConfig as bn, WeappLibEntryContext as br, WeappTailwindcssOptions as bt, UserConfigFnPromise as c, WxmlValidationContext as cn, StyleConfigEntry as cr, WeappCompilerSourceClaim as ct, Component$1 as d, WxmlAttribute as dn, StyleScope as dr, ProjectConfig as dt, WeappVueConfig as en, NpmPluginPackageConfig as er, WeappCompilerPlugin as et, Page$1 as f, WxmlAttributeValue as fn, SubPackage as fr, SubPackageMetaValue as ft, defineComponentJson as g, WxmlTransformContext as gn, SubPackageStyleScope as gr, WeappAnalyzeHistoryConfig as gt, defineAppJson as h, WxmlTransform as hn, SubPackageStyleEntry as hr, WeappAnalyzeConfig as ht, UserConfigFnNoEnv as i, WeappWorkerConfig as in, SharedChunkDynamicImports as ir, WeappCompilerPluginFactory as it, ResolvedConfig$1 as j, GenerateExtensionsOptions as jn, WeappViteHostMeta as jr, WeappAppPreludeMode as jt, PluginOption as k, DeprecatedInlineDynamicImports as kn, WeappWebConfig as kr, ScanWxmlOptions as kt, defineConfig as l, WxmlValidationDiagnostic as ln, StyleConfigObject as lr, WeappCompilerSourceRequest as lt, Theme$1 as m, WxmlSourceLocation as mn, SubPackageStyleConfigObject as mr, WeappAnalyzeBudgetConfig as mt, UserConfigExport as n, WeappWebRuntimeConfig as nn, NpmSubPackageConfig as nr, WeappCompilerPluginContext as nt, UserConfigFnObject as o, WxmlRemoveOptions as on, SharedChunkOverride as or, WeappCompilerPluginPhase as ot, Sitemap$1 as p, WxmlElementInfo as pn, SubPackageStyleConfigEntry as pr, UserConfig$2 as pt, ComponentsMap as q, JsonMergeStage as qn, isWebPlatform as qr, WeappReactCompilerConfig as qt, UserConfigFn as r, WeappWevuConfig as rn, ResolvedAlias as rr, WeappCompilerPluginController as rt, UserConfigFnObjectPlain as s, WxmlValidate as sn, SharedChunkStrategy as sr, WeappCompilerResourceKind as st, UserConfig$1 as t, WeappVueTemplateConfig as tn, NpmStrategy as tr, WeappCompilerPluginCapabilities as tt, App$1 as u, WxmlValidationVisitor as un, StyleEntry as ur, WeappCompilerTransformResult as ut, defineSitemapJson as v, WxmlTransformResult as vn, WeappLibConfig as vr, WeappForwardConsoleConfig as vt, ComputedDefinitions$1 as w, AlipayNpmMode as wn, WeappManagedAppTsconfigConfig as wr, AutoImportComponentsOption as wt, WeappVitePluginApi as x, MultiPlatformProjectConfigs as xn, WeappLibFileName as xr, WeappUploadConfig as xt, defineThemeJson as y, WxmlTransformVisitor as yn, WeappLibDtsOptions as yr, WeappForwardConsoleLogLevel as yt, ViteDevServer$1 as z, GenerateTemplateFileSource as zn, WeappVitePlatform as zr, WeappInjectRequestGlobalsTarget as zt };
|
package/dist/config.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { Ar as WEAPP_VITE_HOST_NAME, Br as WeappViteRuntime, Fr as resolveWeappViteHostMeta, Gn as JsonMergeContext, Jn as JsonMergeStrategy, Kn as JsonMergeFunction, Mr as applyWeappViteHostMeta, Nr as createWeappViteHostMeta, Pr as isWeappViteHost, Q as WeappCompilerHmrRequest, St as WeappViteConfig, Wn as JsonConfig, X as WeappCompilerHmrAsset, Z as WeappCompilerHmrPreparation, _ as definePageJson, _n as WxmlTransformNode, a as UserConfigFnNoEnvPlain, an as WxmlRemoveAttrRule, at as WeappCompilerPluginOption, bn as MultiPlatformProjectConfig, c as UserConfigFnPromise, cn as WxmlValidationContext, d as Component, dn as WxmlAttribute, et as WeappCompilerPlugin, f as Page, fn as WxmlAttributeValue, g as defineComponentJson, gn as WxmlTransformContext, h as defineAppJson, hn as WxmlTransform, i as UserConfigFnNoEnv, jr as WeappViteHostMeta, l as defineConfig, ln as WxmlValidationDiagnostic, m as Theme, mn as WxmlSourceLocation, n as UserConfigExport, nt as WeappCompilerPluginContext, o as UserConfigFnObject, on as WxmlRemoveOptions, p as Sitemap, pn as WxmlElementInfo, qn as JsonMergeStage, r as UserConfigFn, rt as WeappCompilerPluginController, s as UserConfigFnObjectPlain, sn as WxmlValidate, t as UserConfig, tt as WeappCompilerPluginCapabilities, u as App, un as WxmlValidationVisitor, v as defineSitemapJson, vn as WxmlTransformResult, xn as MultiPlatformProjectConfigs, y as defineThemeJson, yn as WxmlTransformVisitor } from "./config-
|
|
2
|
-
import { t as WeappI18nConfig } from "./types-
|
|
1
|
+
import { Ar as WEAPP_VITE_HOST_NAME, Br as WeappViteRuntime, Fr as resolveWeappViteHostMeta, Gn as JsonMergeContext, Jn as JsonMergeStrategy, Kn as JsonMergeFunction, Mr as applyWeappViteHostMeta, Nr as createWeappViteHostMeta, Pr as isWeappViteHost, Q as WeappCompilerHmrRequest, St as WeappViteConfig, Wn as JsonConfig, X as WeappCompilerHmrAsset, Z as WeappCompilerHmrPreparation, _ as definePageJson, _n as WxmlTransformNode, a as UserConfigFnNoEnvPlain, an as WxmlRemoveAttrRule, at as WeappCompilerPluginOption, bn as MultiPlatformProjectConfig, c as UserConfigFnPromise, cn as WxmlValidationContext, d as Component, dn as WxmlAttribute, et as WeappCompilerPlugin, f as Page, fn as WxmlAttributeValue, g as defineComponentJson, gn as WxmlTransformContext, h as defineAppJson, hn as WxmlTransform, i as UserConfigFnNoEnv, jr as WeappViteHostMeta, l as defineConfig, ln as WxmlValidationDiagnostic, m as Theme, mn as WxmlSourceLocation, n as UserConfigExport, nt as WeappCompilerPluginContext, o as UserConfigFnObject, on as WxmlRemoveOptions, p as Sitemap, pn as WxmlElementInfo, qn as JsonMergeStage, r as UserConfigFn, rt as WeappCompilerPluginController, s as UserConfigFnObjectPlain, sn as WxmlValidate, t as UserConfig, tt as WeappCompilerPluginCapabilities, u as App, un as WxmlValidationVisitor, v as defineSitemapJson, vn as WxmlTransformResult, xn as MultiPlatformProjectConfigs, y as defineThemeJson, yn as WxmlTransformVisitor } from "./config-BNx2BODw.mjs";
|
|
2
|
+
import { t as WeappI18nConfig } from "./types-e2BMP9NU.mjs";
|
|
3
3
|
export { type App, type Component, type JsonConfig, type JsonMergeContext, type JsonMergeFunction, type JsonMergeStage, type JsonMergeStrategy, type MultiPlatformProjectConfig, type MultiPlatformProjectConfigs, type Page, type Sitemap, type Theme, UserConfig, UserConfigExport, UserConfigFn, UserConfigFnNoEnv, UserConfigFnNoEnvPlain, UserConfigFnObject, UserConfigFnObjectPlain, UserConfigFnPromise, WEAPP_VITE_HOST_NAME, type WeappCompilerHmrAsset, type WeappCompilerHmrPreparation, type WeappCompilerHmrRequest, type WeappCompilerPlugin, type WeappCompilerPluginCapabilities, type WeappCompilerPluginContext, type WeappCompilerPluginController, type WeappCompilerPluginOption, type WeappI18nConfig, type WeappViteConfig, WeappViteHostMeta, type WeappViteRuntime, type WxmlAttribute, type WxmlAttributeValue, type WxmlElementInfo, type WxmlRemoveAttrRule, type WxmlRemoveOptions, type WxmlSourceLocation, type WxmlTransform, type WxmlTransformContext, type WxmlTransformNode, type WxmlTransformResult, type WxmlTransformVisitor, type WxmlValidate, type WxmlValidationContext, type WxmlValidationDiagnostic, type WxmlValidationVisitor, applyWeappViteHostMeta, createWeappViteHostMeta, defineAppJson, defineComponentJson, defineConfig, definePageJson, defineSitemapJson, defineThemeJson, isWeappViteHost, resolveWeappViteHostMeta };
|
package/dist/config.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as resolveWeappViteHostMeta, i as isWeappViteHost, n as applyWeappViteHostMeta, r as createWeappViteHostMeta, t as WEAPP_VITE_HOST_NAME } from "./pluginHost
|
|
2
|
-
import { a as defineThemeJson, i as defineSitemapJson, n as defineComponentJson, r as definePageJson, t as defineAppJson } from "./json-
|
|
3
|
-
import { t as defineConfig } from "./config-
|
|
1
|
+
import { a as resolveWeappViteHostMeta, i as isWeappViteHost, n as applyWeappViteHostMeta, r as createWeappViteHostMeta, t as WEAPP_VITE_HOST_NAME } from "./pluginHost-vn8Vty1J.mjs";
|
|
2
|
+
import { a as defineThemeJson, i as defineSitemapJson, n as defineComponentJson, r as definePageJson, t as defineAppJson } from "./json-Cvon2mw5.mjs";
|
|
3
|
+
import { t as defineConfig } from "./config-59ZWhCIf.mjs";
|
|
4
4
|
export { WEAPP_VITE_HOST_NAME, applyWeappViteHostMeta, createWeappViteHostMeta, defineAppJson, defineComponentJson, defineConfig, definePageJson, defineSitemapJson, defineThemeJson, isWeappViteHost, resolveWeappViteHostMeta };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as MINI_PROGRAM_PLATFORM_ADAPTERS } from "./adapters-CcHrsYaj.mjs";
|
|
2
|
-
|
|
2
|
+
// src/platforms/sourceAssets.ts
|
|
3
3
|
const PORTABLE_TEMPLATE_EXTENSIONS = ["wxml", "html"];
|
|
4
4
|
const PORTABLE_STYLE_EXTENSIONS = [
|
|
5
5
|
"wxss",
|
|
@@ -48,8 +48,7 @@ function isNativeTemplateSource(filePath, platform) {
|
|
|
48
48
|
const nativeExtension = getAdapter(platform)?.outputExtensions.wxml;
|
|
49
49
|
return Boolean(nativeExtension && filePath.endsWith(`.${nativeExtension}`));
|
|
50
50
|
}
|
|
51
|
-
|
|
52
|
-
//#region src/constants.ts
|
|
51
|
+
// src/constants.ts
|
|
53
52
|
const VERSION = "__VERSION__";
|
|
54
53
|
/**
|
|
55
54
|
* 源代码支持的 js 文件格式
|
|
@@ -81,5 +80,4 @@ const supportedCssLangs = ALL_SOURCE_STYLE_EXTENSIONS;
|
|
|
81
80
|
* 源代码支持的 wxml 文件格式
|
|
82
81
|
*/
|
|
83
82
|
const templateExtensions = ALL_SOURCE_TEMPLATE_EXTENSIONS;
|
|
84
|
-
//#endregion
|
|
85
83
|
export { supportedCssLangs as a, ALL_NATIVE_STYLE_RESOLVER_EXTENSIONS as c, isNativeTemplateSource as d, isSourceStyleExtension as f, scriptExtensions as i, getSourceStyleExtensions as l, configExtensions as n, templateExtensions as o, isSourceTemplateExtension as p, jsExtensions as r, vueExtensions as s, VERSION as t, getSourceTemplateExtensions as u };
|