weapp-vite 7.10.0 → 7.11.0-dev.20261112.2
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/{action-5b4_Id41.mjs → action-1WhhOkEA.mjs} +5 -5
- package/dist/{action-C69IwqF6.mjs → action-BiI1FA5h.mjs} +4 -4
- package/dist/{action-DeTIjVZi.mjs → action-CXBKsOah.mjs} +1 -1
- package/dist/{action-BrYUOyNr.mjs → action-CaQDhcrv.mjs} +2 -2
- package/dist/{action-D5YjMuNK.mjs → action-CcPxY4jY.mjs} +6 -6
- package/dist/{assets-DGjxkFom.mjs → assets-DyhtuWu1.mjs} +1 -1
- package/dist/auto-routes.mjs +2 -2
- package/dist/{classifier-CBLOs0e9.mjs → classifier-Dwmknymp.mjs} +2 -2
- package/dist/cli-acceptance.mjs +1 -1
- package/dist/cli.mjs +14 -14
- package/dist/{config-CsQjaqsL.d.mts → config-BBitSuc3.d.mts} +1 -0
- package/dist/config.d.mts +1 -1
- package/dist/{createCompilerContextInstance-DLbj9x6v.mjs → createCompilerContextInstance-C78SCHEx.mjs} +19748 -987
- package/dist/{createContext-CNX394Nq.mjs → createContext-DU7hZLmD.mjs} +2 -2
- package/dist/docs/weapp-config.md +2 -2
- package/dist/doctor-worker.mjs +1 -1
- package/dist/doctor.d.mts +1 -1
- package/dist/doctor.mjs +2 -2
- package/dist/file-D2CLFlim.mjs +1 -0
- package/dist/{file-BKX2bE_I.mjs → file-gK1WU_h7.mjs} +1 -1
- package/dist/{forwardConsole-Bd9pQVs_.mjs → forwardConsole-Dq7kJoEn.mjs} +1 -1
- package/dist/{getInstance-BFOSqiSf.mjs → getInstance-D52Jif8h.mjs} +1 -1
- package/dist/getInstance-cckFQqcW.mjs +1 -0
- package/dist/{history-D3m367Ml.mjs → history-DtRVxipc.mjs} +2 -2
- package/dist/index.d.mts +1 -1
- package/dist/index.mjs +2 -2
- package/dist/json.d.mts +1 -1
- package/dist/{lib-TVTxVvtt.mjs → lib-CnMZItFq.mjs} +1 -1
- package/dist/loadConfig--xd3UgSE.mjs +1 -0
- package/dist/{loadConfig-DBH8TMJu.mjs → loadConfig-CRNTCJEy.mjs} +1 -1
- package/dist/{logBuildAppFinish-CiwAAttq.mjs → logBuildAppFinish-2lCdPemr.mjs} +1 -1
- package/dist/{mcp-CUJeEA1k.mjs → mcp-BZJ36YYg.mjs} +1 -1
- package/dist/mcp.d.mts +1 -1
- package/dist/{openIde-MbhME5Lq.mjs → openIde-CUB-aFWD.mjs} +2 -2
- package/dist/{package-DaAwtXIg.mjs → package-DKOy7VjA.mjs} +2 -2
- package/dist/rolldown-runtime-JF607Er3.mjs +4 -0
- package/dist/{runtime-CXXzD_vv.mjs → runtime-CK6qUfap.mjs} +1 -1
- package/dist/{session-OfpAb3Zc.mjs → session-D6PfwMgu.mjs} +19 -8
- package/dist/test.mjs +1 -1
- package/dist/types.d.mts +1 -1
- package/dist/{utils-BiSQAI-e.mjs → utils-BfnYilz4.mjs} +1 -1
- package/dist/vite.d.mts +1 -1
- package/dist/vite.mjs +1 -1
- package/package.json +34 -26
- package/skills/weapp-vite-best-practices/references/stateful-hmr-playbook.md +3 -1
- package/dist/file-WUM9I-Hl.mjs +0 -1
- package/dist/getInstance-BkoPIV8s.mjs +0 -1
- package/dist/loadConfig-DrcfCgLX.mjs +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as resetCompilerContext, r as setActiveCompilerContextKey, t as getCompilerContext } from "./getInstance-
|
|
2
|
-
import { j as initializeCompilerContext } from "./createCompilerContextInstance-
|
|
1
|
+
import { n as resetCompilerContext, r as setActiveCompilerContextKey, t as getCompilerContext } from "./getInstance-D52Jif8h.mjs";
|
|
2
|
+
import { j as initializeCompilerContext } from "./createCompilerContextInstance-C78SCHEx.mjs";
|
|
3
3
|
// src/createContext.ts
|
|
4
4
|
/** 保留历史活动上下文适配;新宿主通过 CompilerSession 创建独立会话。 */
|
|
5
5
|
async function createCompilerContext(options) {
|
|
@@ -640,7 +640,7 @@ export default defineConfig({
|
|
|
640
640
|
})
|
|
641
641
|
```
|
|
642
642
|
|
|
643
|
-
安全的 JavaScript/Vue 更新会保留当前 Page/Component 实例、route/query、输入和可序列化 data/setup ref,并替换原生 Page、原生 Component 与 wevu
|
|
643
|
+
安全的 JavaScript/Vue 更新会保留当前 Page/Component 实例、route/query、输入和可序列化 data/setup ref,并替换原生 Page、原生 Component 与 wevu 方法。模板字节、编译后样式、JSON/配置和不兼容模块图变化会自动切换 classic 完整发布,本次 dev 命令保持 classic,重启后重新检测。静态资源更新按实际产物判断;普通编译或业务异常保留原始诊断,不冒充能力降级,失败批次不推进交付版本,修复源码后的下一次保存继续重试。classic 完整刷新会重置运行状态。
|
|
644
644
|
|
|
645
645
|
入口拓扑更新先验证完整快照,再把仍符合源目录和声明依赖内容版本的快照一次性交给新宿主,避免重复编译。输入变化、依赖覆盖不足或固定输入批次无法验证时重新构建;快照失败时保留旧宿主,修复尚未进入旧图的新文件也能触发重试。会话关闭会取消未交接的候选。
|
|
646
646
|
|
|
@@ -650,7 +650,7 @@ Vue `<style module>` 会生成脚本中的类名映射,因此其内容、模
|
|
|
650
650
|
|
|
651
651
|
回退时,同一输出当前收集到的多个 sidecar 按收集顺序合并后一次发布,不会相互覆盖;指向同一真实文件的重复路径只保留一份。常规 HMR 更新按完整合并内容去重,而不是分别缓存每个片段。
|
|
652
652
|
|
|
653
|
-
|
|
653
|
+
模板和样式写出不代表 IDE 已应用;当前宿主缺少可靠状态保持应用确认时走 classic。构建发布、脚本执行确认和完整重载分别验收;旧 build/client 的异步确认不能完成新一代同名产物。
|
|
654
654
|
|
|
655
655
|
`auto` 在 `project.private.config.json` 的 `setting.compileHotReLoad` 严格为 `true` 时选择 `stateful-experimental`,否则选择 `classic`;非微信平台也会回退到 `classic`。该判断只在启动时执行,修改开发者工具设置后需要重启 `wv dev`。启动日志会以 `HMR 模式` 和 `HMR 切换` 两行显示最终模式、选择来源,以及通过 DevTools 热重载开关或 `weapp.hmr.runtime` 切换模式的方法。显式配置通常优先,但 Skyline 兼容降级不受显式配置覆盖。
|
|
656
656
|
|
package/dist/doctor-worker.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as resolveAnalyzeBudgets } from "./metadata-HlDKtlsu.mjs";
|
|
2
2
|
import { t as terminateStaleSassEmbeddedProcess } from "./processCleanup-DzB64WI8.mjs";
|
|
3
|
-
import { t as createCompilerContext } from "./createContext-
|
|
3
|
+
import { t as createCompilerContext } from "./createContext-DU7hZLmD.mjs";
|
|
4
4
|
import { r as readDoctorFiles } from "./files-Cy9jURJu.mjs";
|
|
5
5
|
import process from "node:process";
|
|
6
6
|
import path from "node:path";
|
package/dist/doctor.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { i as AnalyzeBudgetConfig } from "./budget-DTPngJU0.mjs";
|
|
2
|
-
import { Yn as MpPlatform } from "./config-
|
|
2
|
+
import { Yn as MpPlatform } from "./config-BBitSuc3.mjs";
|
|
3
3
|
import { OperationDiagnostics } from "@weapp-vite/miniprogram-automator";
|
|
4
4
|
type DoctorLayer = 'project' | 'source' | 'artifact' | 'runtime';
|
|
5
5
|
interface DoctorCoverage {
|
package/dist/doctor.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { l as getProjectPlatformOptions, m as resolveMiniPlatform, o as getPlatformOutputExtensions } from "./platform-BiMpsZIb.mjs";
|
|
2
|
-
import { t as classifyPackage } from "./classifier-
|
|
2
|
+
import { t as classifyPackage } from "./classifier-Dwmknymp.mjs";
|
|
3
3
|
import { t as createAnalyzeBudgetCheck } from "./budget-_Mu-4GKn.mjs";
|
|
4
4
|
import { n as parseObject, r as readDoctorFiles, t as objectValue } from "./files-Cy9jURJu.mjs";
|
|
5
|
-
import { E as outputTemplateParser, N as getScriptModuleImportAttrs, O as getTemplateImportAttrs, n as version } from "./package-
|
|
5
|
+
import { E as outputTemplateParser, N as getScriptModuleImportAttrs, O as getTemplateImportAttrs, n as version } from "./package-DKOy7VjA.mjs";
|
|
6
6
|
import process from "node:process";
|
|
7
7
|
import { constants } from "node:fs";
|
|
8
8
|
import { fileURLToPath } from "node:url";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { t as extractConfigFromVue } from "./file-gK1WU_h7.mjs";
|
|
@@ -55,7 +55,7 @@ function resolveAutoRoutesMacroImportPath() {
|
|
|
55
55
|
}
|
|
56
56
|
async function resolveAutoRoutesInlineSnapshot(context) {
|
|
57
57
|
try {
|
|
58
|
-
const compilerContext = context ?? (await import("./getInstance-
|
|
58
|
+
const compilerContext = context ?? (await import("./getInstance-cckFQqcW.mjs")).getCompilerContext();
|
|
59
59
|
const service = compilerContext.autoRoutesService;
|
|
60
60
|
const reference = service?.getReference?.();
|
|
61
61
|
if (!compilerContext.runtimeState.autoRoutes.loadingAppConfig) await service?.ensureFresh?.();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { f as resolveHmrProfileJsonPath } from "./devProvider-Ci2il72x.mjs";
|
|
2
2
|
import { r as logger_default, t as colors } from "./logger-DGn5iEVN.mjs";
|
|
3
|
-
import { a as resolveIdeProjectRoot, o as shouldUseAutomatorProjectWrapper } from "./openIde-
|
|
3
|
+
import { a as resolveIdeProjectRoot, o as shouldUseAutomatorProjectWrapper } from "./openIde-CUB-aFWD.mjs";
|
|
4
4
|
import { t as readHmrProfileLines } from "./reader-wzPH_W8A.mjs";
|
|
5
5
|
import process from "node:process";
|
|
6
6
|
import { fs } from "@weapp-core/shared/fs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as createCompilerContextInstance } from "./createCompilerContextInstance-
|
|
1
|
+
import { t as createCompilerContextInstance } from "./createCompilerContextInstance-C78SCHEx.mjs";
|
|
2
2
|
// src/context/getInstance.ts
|
|
3
3
|
const compilerContextMap = /* @__PURE__ */ new Map();
|
|
4
4
|
const DEFAULT_KEY = "default";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { t as getCompilerContext } from "./getInstance-D52Jif8h.mjs";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { c as getDevServerCloseRecord, l as replaceDevServerClose, s as getDevShutdownScope } from "./lifecycle-Dt0rvANg.mjs";
|
|
2
|
-
import { C as createDevViteServer, T as createGlassEaselAnalyzeResult, k as createSharedBuildConfig } from "./createCompilerContextInstance-
|
|
2
|
+
import { C as createDevViteServer, T as createGlassEaselAnalyzeResult, k as createSharedBuildConfig } from "./createCompilerContextInstance-C78SCHEx.mjs";
|
|
3
3
|
import { r as logger_default, t as colors } from "./logger-DGn5iEVN.mjs";
|
|
4
4
|
import { a as resolveDashboardInstallation, r as ANALYZE_DASHBOARD_PACKAGE_NAME } from "./artifacts-TrTX9_jj.mjs";
|
|
5
5
|
import { t as loadDashboardTransportModule } from "./dashboardTransport-C9290QgS.mjs";
|
|
6
6
|
import { n as isRuntimeCategory, t as createAnalyzeBudgetCheck } from "./budget-_Mu-4GKn.mjs";
|
|
7
7
|
import { r as resolveAnalyzeHistoryMetadata, t as createAnalyzeMetadata } from "./metadata-HlDKtlsu.mjs";
|
|
8
|
-
import { i as resolveModuleSourceType, n as normalizeModuleId, r as resolveAssetSource, t as classifyPackage } from "./classifier-
|
|
8
|
+
import { i as resolveModuleSourceType, n as normalizeModuleId, r as resolveAssetSource, t as classifyPackage } from "./classifier-Dwmknymp.mjs";
|
|
9
9
|
import process from "node:process";
|
|
10
10
|
import path, { posix } from "pathe";
|
|
11
11
|
import { readFileSync } from "node:fs";
|
package/dist/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as WeappCompilerOutputRequest, A as Ref, Ar as WEAPP_VITE_HOST_NAME, Br as WeappViteRuntime, C as LoadConfigOptions, D as MethodDefinitions, E as InlineConfig, F as RolldownPlugin, Fr as resolveWeappViteHostMeta, Gn as JsonMergeContext, Gr as getSupportedWeappVitePlatforms, Hr as WeappViteTargetInput, I as RolldownPluginOption, Ir as ResolveWeappViteTargetOptions, Jn as JsonMergeStrategy, Jr as resolveWeappViteTarget, Kn as JsonMergeFunction, Kr as getSupportedWeappViteTargetDescriptors, L as RolldownWatchOptions, Lr as ResolvedWeappViteTarget, M as RolldownBuild, Mr as applyWeappViteHostMeta, N as RolldownOptions, Nr as createWeappViteHostMeta, O as Plugin, P as RolldownOutput, Pr as isWeappViteHost, Q as WeappCompilerHmrRequest, R as RolldownWatcher, Rr as WEB_PLATFORM_ALIASES, S as CompilerContext, St as WeappViteConfig, T as ConfigEnv, Ur as WeappViteTargetKind, Vr as WeappViteTargetDescriptor, Wn as JsonConfig, Wr as WebPlatform, 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, ct as WeappCompilerSourceClaim, 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, it as WeappCompilerPluginFactory, j as ResolvedConfig, jr as WeappViteHostMeta, k as PluginOption, l as defineConfig, ln as WxmlValidationDiagnostic, lt as WeappCompilerSourceRequest, m as Theme, mn as WxmlSourceLocation, n as UserConfigExport, nt as WeappCompilerPluginContext, o as UserConfigFnObject, on as WxmlRemoveOptions, ot as WeappCompilerPluginPhase, p as Sitemap, pn as WxmlElementInfo, qn as JsonMergeStage, qr as isWebPlatform, r as UserConfigFn, rt as WeappCompilerPluginController, s as UserConfigFnObjectPlain, sn as WxmlValidate, st as WeappCompilerResourceKind, t as UserConfig, tt as WeappCompilerPluginCapabilities, u as App, un as WxmlValidationVisitor, ut as WeappCompilerTransformResult, v as defineSitemapJson, vn as WxmlTransformResult, w as ComputedDefinitions, xn as MultiPlatformProjectConfigs, y as defineThemeJson, yn as WxmlTransformVisitor, z as ViteDevServer, zr as WeappVitePlatform } from "./config-
|
|
1
|
+
import { $ as WeappCompilerOutputRequest, A as Ref, Ar as WEAPP_VITE_HOST_NAME, Br as WeappViteRuntime, C as LoadConfigOptions, D as MethodDefinitions, E as InlineConfig, F as RolldownPlugin, Fr as resolveWeappViteHostMeta, Gn as JsonMergeContext, Gr as getSupportedWeappVitePlatforms, Hr as WeappViteTargetInput, I as RolldownPluginOption, Ir as ResolveWeappViteTargetOptions, Jn as JsonMergeStrategy, Jr as resolveWeappViteTarget, Kn as JsonMergeFunction, Kr as getSupportedWeappViteTargetDescriptors, L as RolldownWatchOptions, Lr as ResolvedWeappViteTarget, M as RolldownBuild, Mr as applyWeappViteHostMeta, N as RolldownOptions, Nr as createWeappViteHostMeta, O as Plugin, P as RolldownOutput, Pr as isWeappViteHost, Q as WeappCompilerHmrRequest, R as RolldownWatcher, Rr as WEB_PLATFORM_ALIASES, S as CompilerContext, St as WeappViteConfig, T as ConfigEnv, Ur as WeappViteTargetKind, Vr as WeappViteTargetDescriptor, Wn as JsonConfig, Wr as WebPlatform, 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, ct as WeappCompilerSourceClaim, 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, it as WeappCompilerPluginFactory, j as ResolvedConfig, jr as WeappViteHostMeta, k as PluginOption, l as defineConfig, ln as WxmlValidationDiagnostic, lt as WeappCompilerSourceRequest, m as Theme, mn as WxmlSourceLocation, n as UserConfigExport, nt as WeappCompilerPluginContext, o as UserConfigFnObject, on as WxmlRemoveOptions, ot as WeappCompilerPluginPhase, p as Sitemap, pn as WxmlElementInfo, qn as JsonMergeStage, qr as isWebPlatform, r as UserConfigFn, rt as WeappCompilerPluginController, s as UserConfigFnObjectPlain, sn as WxmlValidate, st as WeappCompilerResourceKind, t as UserConfig, tt as WeappCompilerPluginCapabilities, u as App, un as WxmlValidationVisitor, ut as WeappCompilerTransformResult, v as defineSitemapJson, vn as WxmlTransformResult, w as ComputedDefinitions, xn as MultiPlatformProjectConfigs, y as defineThemeJson, yn as WxmlTransformVisitor, z as ViteDevServer, zr as WeappVitePlatform } from "./config-BBitSuc3.mjs";
|
|
2
2
|
import { t as WeappI18nConfig } from "./types-e2BMP9NU.mjs";
|
|
3
3
|
import { a as LayoutHostContext, c as LayoutHostResolver, d as unregisterLayoutHosts, f as waitForLayoutHost, i as LayoutHostBridge, l as registerLayoutHosts, m as createWevuComponent, n as defineProps, o as LayoutHostEntry, p as WevuComponentOptions, r as setPageLayout, s as LayoutHostResolveOptions, t as defineEmits, u as resolveLayoutHost } from "./runtime-BL4RjBRa.mjs";
|
|
4
4
|
interface InitializeCompilerContextOptions extends Partial<LoadConfigOptions> {
|
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as defineConfig } from "./config-59ZWhCIf.mjs";
|
|
2
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 createCompilerContext } from "./createContext-
|
|
3
|
+
import { t as createCompilerContext } from "./createContext-DU7hZLmD.mjs";
|
|
4
4
|
import { a as resolveWeappViteHostMeta, i as isWeappViteHost, n as applyWeappViteHostMeta, r as createWeappViteHostMeta, t as WEAPP_VITE_HOST_NAME } from "./pluginHost-vn8Vty1J.mjs";
|
|
5
5
|
import { a as resolveLayoutHost, c as createWevuComponent, i as registerLayoutHosts, n as defineProps, o as unregisterLayoutHosts, r as setPageLayout, s as waitForLayoutHost, t as defineEmits } from "./runtime-DDUCb7pP.mjs";
|
|
6
|
-
import { a as getSupportedWeappViteTargetDescriptors, i as getSupportedWeappVitePlatforms, o as isWebPlatform, r as WEB_PLATFORM_ALIASES, s as resolveWeappViteTarget } from "./createCompilerContextInstance-
|
|
6
|
+
import { a as getSupportedWeappViteTargetDescriptors, i as getSupportedWeappVitePlatforms, o as isWebPlatform, r as WEB_PLATFORM_ALIASES, s as resolveWeappViteTarget } from "./createCompilerContextInstance-C78SCHEx.mjs";
|
|
7
7
|
export { WEAPP_VITE_HOST_NAME, WEB_PLATFORM_ALIASES, applyWeappViteHostMeta, createCompilerContext, createWeappViteHostMeta, createWevuComponent, defineAppJson, defineComponentJson, defineConfig, defineEmits, definePageJson, defineProps, defineSitemapJson, defineThemeJson, getSupportedWeappVitePlatforms, getSupportedWeappViteTargetDescriptors, isWeappViteHost, isWebPlatform, registerLayoutHosts, resolveLayoutHost, resolveWeappViteHostMeta, resolveWeappViteTarget, setPageLayout, unregisterLayoutHosts, waitForLayoutHost };
|
package/dist/json.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { _ as definePageJson, d as Component, f as Page, g as defineComponentJson, h as defineAppJson, m as Theme, p as Sitemap, u as App, v as defineSitemapJson, y as defineThemeJson } from "./config-
|
|
1
|
+
import { _ as definePageJson, d as Component, f as Page, g as defineComponentJson, h as defineAppJson, m as Theme, p as Sitemap, u as App, v as defineSitemapJson, y as defineThemeJson } from "./config-BBitSuc3.mjs";
|
|
2
2
|
export { type App, type Component, type Page, type Sitemap, type Theme, defineAppJson, defineComponentJson, definePageJson, defineSitemapJson, defineThemeJson };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { o as stripLeadingSlashes, r as normalizeRelativePath } from "./path-E1OjBJAl.mjs";
|
|
2
|
-
import { c as findJsEntry, d as findVueEntry } from "./file-
|
|
2
|
+
import { c as findJsEntry, d as findVueEntry } from "./file-gK1WU_h7.mjs";
|
|
3
3
|
import path from "pathe";
|
|
4
4
|
import { isObject, removeExtensionDeep } from "@weapp-core/shared";
|
|
5
5
|
import { fs } from "@weapp-core/shared/fs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { t as loadConfig } from "./loadConfig-CRNTCJEy.mjs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as createCjsConfigLoadError, C as loadViteConfigFile, t as resolveWeappConfigFile } from "./utils-
|
|
1
|
+
import { A as createCjsConfigLoadError, C as loadViteConfigFile, t as resolveWeappConfigFile } from "./utils-BfnYilz4.mjs";
|
|
2
2
|
import process from "node:process";
|
|
3
3
|
import path from "pathe";
|
|
4
4
|
import { defu } from "@weapp-core/shared";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { s as getProjectConfigFileName } from "./utils-
|
|
1
|
+
import { s as getProjectConfigFileName } from "./utils-BfnYilz4.mjs";
|
|
2
2
|
import { r as logger_default, t as colors } from "./logger-DGn5iEVN.mjs";
|
|
3
3
|
import process from "node:process";
|
|
4
4
|
import { resolveCommand } from "package-manager-detector/commands";
|
|
@@ -77,7 +77,7 @@ function registerAcceptCommand(cli) {
|
|
|
77
77
|
// src/cli/commands/mcp/index.ts
|
|
78
78
|
function registerMcpCommand(cli) {
|
|
79
79
|
cli.command("mcp [...args]", "start weapp-vite MCP server or manage MCP client onboarding").option("--transport <type>", "[string] stdio | streamable-http | command | http", { default: "stdio" }).option("--host <host>", "[string] streamable-http host").option("--port <port>", "[number] streamable-http port").option("--endpoint <path>", "[string] streamable-http endpoint path").option("--rest-endpoint <path>", "[string] streamable-http REST runtime endpoint path").option("--no-rest", "[boolean] disable streamable-http REST runtime endpoints").option("--unref", "[boolean] unref HTTP server to not block process exit").option("--url <url>", "[string] explicit HTTP MCP url").option("--workspace-root <path>", "[string] workspace root path, defaults to cwd").option("-y, --yes", "[boolean] write config without prompt").action(async (args, options) => {
|
|
80
|
-
const { runMcpCommand } = await import("./action-
|
|
80
|
+
const { runMcpCommand } = await import("./action-CXBKsOah.mjs");
|
|
81
81
|
return runMcpCommand(args, options);
|
|
82
82
|
});
|
|
83
83
|
}
|
package/dist/mcp.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Ut as WeappMcpConfig } from "./config-
|
|
1
|
+
import { Ut as WeappMcpConfig } from "./config-BBitSuc3.mjs";
|
|
2
2
|
import { DEFAULT_MCP_ENDPOINT, DEFAULT_MCP_HOST, DEFAULT_MCP_PORT, DEFAULT_RUNTIME_REST_ENDPOINT } from "@weapp-core/constants";
|
|
3
3
|
import { CreateServerOptions, McpServerHandle, StartMcpServerOptions, createWeappViteMcpServer as createWeappViteMcpServer$1 } from "@weapp-vite/mcp";
|
|
4
4
|
/** 创建服务时才加载 MCP 运行时;配置解析与公开常量保持同步。 */
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { t as createCompilerContext } from "./createContext-
|
|
1
|
+
import { t as createCompilerContext } from "./createContext-DU7hZLmD.mjs";
|
|
2
2
|
import { r as logger_default, t as colors } from "./logger-DGn5iEVN.mjs";
|
|
3
3
|
import { n as getDefaultIdeProjectRoot, w as shouldPassPlatformArgToIdeOpen } from "./platform-BiMpsZIb.mjs";
|
|
4
|
-
import { i as resolveRuntimeTargets, t as createInlineConfig } from "./runtime-
|
|
4
|
+
import { i as resolveRuntimeTargets, t as createInlineConfig } from "./runtime-CK6qUfap.mjs";
|
|
5
5
|
import process from "node:process";
|
|
6
6
|
import path from "pathe";
|
|
7
7
|
import fs from "node:fs";
|
|
@@ -7,8 +7,8 @@ import { getMiniProgramNativeScriptModules, removeExtensionDeep } from "@weapp-c
|
|
|
7
7
|
import { Buffer } from "node:buffer";
|
|
8
8
|
import MagicString from "magic-string";
|
|
9
9
|
import { defaultTemplateInputRecipe, getTemplatePreset } from "@weapp-vite/wxml/presets";
|
|
10
|
-
import { findScriptClosingTag } from "@weapp-vite/language-service";
|
|
11
10
|
import { compileDialect, createParser } from "@weapp-vite/wxml/core";
|
|
11
|
+
import { findScriptClosingTag } from "@weapp-vite/language-service";
|
|
12
12
|
import remapping from "@jridgewell/remapping";
|
|
13
13
|
// src/utils/wxmlScriptModule.ts
|
|
14
14
|
const IMPORT_SJS_TAG_RE = /<import-sjs([\s\S]*?)>/g;
|
|
@@ -1618,6 +1618,6 @@ function resolveSharedChunkName(options) {
|
|
|
1618
1618
|
return "common";
|
|
1619
1619
|
}
|
|
1620
1620
|
// package.json
|
|
1621
|
-
var version = "7.
|
|
1621
|
+
var version = "7.11.0-dev.20261112.2";
|
|
1622
1622
|
var engines = { "node": "^22.23.4 || ^24.22.1 || >=26.12.1" };
|
|
1623
1623
|
export { isTemplateImportTag as A, shouldNormalizeScriptModuleAttributes as B, normalizeEncodedSourceMapLike as C, platformTemplateParser as D, outputTemplateParser as E, isScriptModuleImportAttr as F, isScriptModuleTagName as I, normalizeImportSjsAttributes as L, getNativeScriptModuleByTag as M, getScriptModuleImportAttrs as N, getTemplateImportAttrs as O, getScriptModuleTagNames as P, resolveScriptModuleTagByPlatform as R, labelSourceMapInput as S, configuredTemplateParser as T, replaceOutputChunkCode as _, DEFAULT_SHARED_CHUNK_STRATEGY as a, syncOutputChunkSourceMapAssets as b, applyRuntimeChunkLocalization as c, appendOutputChunkCode as d, applyAtomicMagicStringChunkRewrite as f, prependOutputChunkCode as g, editOutputChunkCode as h, applySharedChunkStrategy as i, shouldNormalizeTemplateImportSource as j, isTemplateImportAttr as k, assertModuleScopedToRoot as l, applyOutputChunkTransform as m, version as n, SHARED_CHUNK_VIRTUAL_PREFIX as o, applyMagicStringChunkRewrite as p, resolveSharedChunkName as r, SUB_PACKAGE_SHARED_DIR as s, engines as t, resolveSubPackagePrefix as u, replaceOutputChunkCodeRanges as v, resetTakeImportRegistry as w, composeSourceMaps as x, resolveOutputChunkTransformCode as y, resolveScriptModuleTagName as z };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { l as resolveBackendExecution } from "./createCompilerContextInstance-
|
|
1
|
+
import { l as resolveBackendExecution } from "./createCompilerContextInstance-C78SCHEx.mjs";
|
|
2
2
|
import { r as logger_default, t as colors } from "./logger-DGn5iEVN.mjs";
|
|
3
3
|
import { defu } from "@weapp-core/shared";
|
|
4
4
|
// src/cli/runtime.ts
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { B as resolveNpmBuildCandidateDependenciesSync, H as resolveNpmDistDirName, W as resolveTargetDependencies, h as attachDevModuleGraphHost, z as resolveMainBuildDependencyPatterns } from "./devProvider-Ci2il72x.mjs";
|
|
2
|
-
import { A as getHmrRuntimeCapabilityFallback, B as attachHmrRuntimeSession, D as createStatefulHmrHostPlugins, E as attachStatefulHmrHost, F as getInitialBuildInputObservation, I as prepareClassicIdeConfig, L as findSkylineRendererFiles, O as getStatefulHmrHost, P as syncManagedTsconfigFiles, R as resolveHmrRuntimeDecision, S as createOxcRuntimeSupport, V as createHmrRuntimeSession, _ as StatefulHmrSnapshotHandoff, b as getPackNpmRelationList, d as CompilerSession, f as buildStatefulHmrSnapshot, g as prepareStatefulClassicHandoff, h as captureWatchDependencies, k as createSharedBuildConfig, m as checkAppWorkersOptions, p as prepareStatefulHmrSnapshot, u as linkClassicSettlement, v as clearStatefulHmrSnapshot, w as compileIgnored, x as createPackageBuilder, y as offerStatefulHmrSnapshot, z as clearUniAppCompatibilitySession } from "./createCompilerContextInstance-
|
|
2
|
+
import { A as getHmrRuntimeCapabilityFallback, B as attachHmrRuntimeSession, D as createStatefulHmrHostPlugins, E as attachStatefulHmrHost, F as getInitialBuildInputObservation, I as prepareClassicIdeConfig, L as findSkylineRendererFiles, O as getStatefulHmrHost, P as syncManagedTsconfigFiles, R as resolveHmrRuntimeDecision, S as createOxcRuntimeSupport, V as createHmrRuntimeSession, _ as StatefulHmrSnapshotHandoff, b as getPackNpmRelationList, d as CompilerSession, f as buildStatefulHmrSnapshot, g as prepareStatefulClassicHandoff, h as captureWatchDependencies, k as createSharedBuildConfig, m as checkAppWorkersOptions, p as prepareStatefulHmrSnapshot, u as linkClassicSettlement, v as clearStatefulHmrSnapshot, w as compileIgnored, x as createPackageBuilder, y as offerStatefulHmrSnapshot, z as clearUniAppCompatibilitySession } from "./createCompilerContextInstance-C78SCHEx.mjs";
|
|
3
3
|
import { t as resolveRealpath } from "./realpathScope-DwlLaCk3.mjs";
|
|
4
|
-
import { g as pruneOwnedAssetFiles } from "./utils-
|
|
4
|
+
import { g as pruneOwnedAssetFiles } from "./utils-BfnYilz4.mjs";
|
|
5
5
|
import { n as loadHostRolldownBuild } from "./engine-Mnnm_ALP.mjs";
|
|
6
6
|
import process from "node:process";
|
|
7
7
|
import path from "pathe";
|
|
@@ -414,6 +414,7 @@ var WeappBuildSession = class extends CompilerSession {
|
|
|
414
414
|
hostClosing;
|
|
415
415
|
terminalClosing;
|
|
416
416
|
inputRegistration;
|
|
417
|
+
onHostControlReady;
|
|
417
418
|
isWeb = false;
|
|
418
419
|
statefulController;
|
|
419
420
|
constructor(hmrRuntimeSession = createHmrRuntimeSession()) {
|
|
@@ -561,19 +562,28 @@ var WeappBuildSession = class extends CompilerSession {
|
|
|
561
562
|
let started = false;
|
|
562
563
|
let successful = false;
|
|
563
564
|
let reportedReady = false;
|
|
565
|
+
let controlReady = !this.statefulController;
|
|
564
566
|
const reportReady = () => {
|
|
565
|
-
if (started && successful && !reportedReady && !this.isClosing) {
|
|
567
|
+
if (started && successful && controlReady && !reportedReady && !this.isClosing) {
|
|
566
568
|
if (this.statefulController && this.hmrRuntimeSession.phase === "switching") return;
|
|
567
569
|
reportedReady = true;
|
|
568
570
|
if (!this.statefulController) this.hmrRuntimeSession.markClassic();
|
|
569
571
|
server.config.logger.info(`[weapp-vite] 小程序开发产物已就绪 (${this.statefulController ? "stateful-experimental" : "classic"})`);
|
|
570
572
|
}
|
|
571
573
|
};
|
|
572
|
-
if (this.statefulController)
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
574
|
+
if (this.statefulController) {
|
|
575
|
+
this.onClose(attachStatefulHmrHost(this.context, {
|
|
576
|
+
server,
|
|
577
|
+
controller: this.statefulController
|
|
578
|
+
}));
|
|
579
|
+
this.onHostControlReady = () => {
|
|
580
|
+
controlReady = true;
|
|
581
|
+
reportReady();
|
|
582
|
+
};
|
|
583
|
+
this.onClose(() => {
|
|
584
|
+
this.onHostControlReady = void 0;
|
|
585
|
+
});
|
|
586
|
+
} else this.onClose(linkClassicSettlement(this.context, server));
|
|
577
587
|
this.onClose(attachDevModuleGraphHost(this.context, server, (result) => {
|
|
578
588
|
successful = result;
|
|
579
589
|
reportReady();
|
|
@@ -590,6 +600,7 @@ var WeappBuildSession = class extends CompilerSession {
|
|
|
590
600
|
}
|
|
591
601
|
async refreshHostControl() {
|
|
592
602
|
await getStatefulHmrHost(this.context)?.refreshControl?.();
|
|
603
|
+
this.onHostControlReady?.();
|
|
593
604
|
}
|
|
594
605
|
buildDependencies() {
|
|
595
606
|
if (this.isWeb) return Promise.resolve({
|
package/dist/test.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as parseSidecarModuleId, i as parseLogicalEntryId } from "./protocol-HiSJRrSO.mjs";
|
|
2
|
-
import { d as CompilerSession, h as captureWatchDependencies } from "./createCompilerContextInstance-
|
|
2
|
+
import { d as CompilerSession, h as captureWatchDependencies } from "./createCompilerContextInstance-C78SCHEx.mjs";
|
|
3
3
|
import { M as createSidecarWatchOptions, O as createFileWatcher, j as deduplicateCleanupErrors } from "./devProvider-Ci2il72x.mjs";
|
|
4
4
|
import { n as normalizePath, t as isPathInside } from "./path-E1OjBJAl.mjs";
|
|
5
5
|
import process from "node:process";
|
package/dist/types.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { f as Resolver } from "./index-SnaW3cvA.mjs";
|
|
2
2
|
import { n as AutoRoutesSubPackage, t as AutoRoutes } from "./routes-DvAFX29h.mjs";
|
|
3
|
-
import { $ as WeappCompilerOutputRequest, $n as NpmPackageFilesConfig, $t as WeappUniAppConfig, A as Ref, An as GenerateDirsOptions, At as WeappAppPreludeConfig, B as BindingErrorLike, Bn as GenerateTemplateInlineSource, Br as WeappViteRuntime, Bt as WeappInjectWeapiConfig, Cn as AliasOptions, Cr as WeappLibVueTscOptions, Ct as AutoImportComponents, D as MethodDefinitions, Dn as CopyGlobs, Dr as WeappManagedSharedTsconfigConfig, Dt as HandleWxmlOptions, E as InlineConfig, En as ChunksConfig, Er as WeappManagedServerTsconfigConfig, Et as EnhanceWxmlOptions, F as RolldownPlugin, Fn as GenerateTemplate, Ft as WeappBuildScopeConfig, G as EntryJsonFragment, Gn as JsonMergeContext, Gt as WeappPreloadNetwork, H as BaseEntry, Hn as GenerateTemplatesConfig, Ht as WeappInjectWebRuntimeGlobalsTarget, I as RolldownPluginOption, In as GenerateTemplateContext, It as WeappBuildScopeObjectConfig, J as ScanComponentItem, Jn as JsonMergeStrategy, Jt as WeappReactConfig, K as PageEntry, Kn as JsonMergeFunction, Kt as WeappPreloadRule, L as RolldownWatchOptions, Ln as GenerateTemplateEntry, Lt as WeappHmrConfig, M as RolldownBuild, Mn as GenerateFileType, Mt as WeappAutoRoutesConfig, N as RolldownOptions, Nn as GenerateFilenamesOptions, Nt as WeappAutoRoutesInclude, O as Plugin, On as CopyOptions, Or as WeappManagedTypeScriptConfig, Ot as MultiPlatformConfig, P as RolldownOutput, Pn as GenerateOptions, Pt as WeappAutoRoutesIncludePattern, Q as WeappCompilerHmrRequest, Qn as NpmMainPackageConfig, Qt as WeappSubPackageConfig, R as RolldownWatcher, Rn as GenerateTemplateFactory, Rt as WeappInjectRequestGlobalsConfig, Sn as Alias, Sr as WeappLibInternalDtsOptions, St as WeappViteConfig, T as ConfigEnv, Tn as BuildNpmPackageMeta, Tr as WeappManagedNodeTsconfigConfig, Tt as EnhanceOptions, U as ComponentEntry, Un as JsFormat, Ut as WeappMcpConfig, V as AppEntry, Vn as GenerateTemplateScope, Vt as WeappInjectWebRuntimeGlobalsConfig, W as Entry, Wn as JsonConfig, Wt as WeappNpmConfig, X as WeappCompilerHmrAsset, Xn as NpmBuildOptions, Xt as WeappRouteRule, Y as WxmlDep, Yn as MpPlatform, Yt as WeappRequestRuntimeConfig, Z as WeappCompilerHmrPreparation, Zn as NpmDependencyPattern, Zt as WeappRouteRules, _n as WxmlTransformNode, _r as WeappLibComponentJson, _t as WeappDebugConfig, an as WxmlRemoveAttrRule, ar as SharedChunkMode, at as WeappCompilerPluginOption, b as ChangeEvent, bn as MultiPlatformProjectConfig, br as WeappLibEntryContext, bt as WeappTailwindcssOptions, cn as WxmlValidationContext, cr as StyleConfigEntry, ct as WeappCompilerSourceClaim, dn as WxmlAttribute, dr as StyleScope, dt as ProjectConfig, en as WeappVueConfig, er as NpmPluginPackageConfig, et as WeappCompilerPlugin, fn as WxmlAttributeValue, fr as SubPackage, ft as SubPackageMetaValue, gn as WxmlTransformContext, gr as SubPackageStyleScope, gt as WeappAnalyzeHistoryConfig, hn as WxmlTransform, hr as SubPackageStyleEntry, ht as WeappAnalyzeConfig, in as WeappWorkerConfig, ir as SharedChunkDynamicImports, it as WeappCompilerPluginFactory, j as ResolvedConfig, jn as GenerateExtensionsOptions, jr as WeappViteHostMeta, jt as WeappAppPreludeMode, k as PluginOption, kn as DeprecatedInlineDynamicImports, kr as WeappWebConfig, kt as ScanWxmlOptions, ln as WxmlValidationDiagnostic, lr as StyleConfigObject, lt as WeappCompilerSourceRequest, mn as WxmlSourceLocation, mr as SubPackageStyleConfigObject, mt as WeappAnalyzeBudgetConfig, nn as WeappWebRuntimeConfig, nr as NpmSubPackageConfig, nt as WeappCompilerPluginContext, on as WxmlRemoveOptions, or as SharedChunkOverride, ot as WeappCompilerPluginPhase, pn as WxmlElementInfo, pr as SubPackageStyleConfigEntry, pt as UserConfig, q as ComponentsMap, qn as JsonMergeStage, qt as WeappReactCompilerConfig, rn as WeappWevuConfig, rr as ResolvedAlias, rt as WeappCompilerPluginController, sn as WxmlValidate, sr as SharedChunkStrategy, st as WeappCompilerResourceKind, tn as WeappVueTemplateConfig, tr as NpmStrategy, tt as WeappCompilerPluginCapabilities, un as WxmlValidationVisitor, ur as StyleEntry, ut as WeappCompilerTransformResult, vn as WxmlTransformResult, vr as WeappLibConfig, vt as WeappForwardConsoleConfig, w as ComputedDefinitions, wn as AlipayNpmMode, wr as WeappManagedAppTsconfigConfig, wt as AutoImportComponentsOption, x as WeappVitePluginApi, xn as MultiPlatformProjectConfigs, xr as WeappLibFileName, xt as WeappUploadConfig, yn as WxmlTransformVisitor, yr as WeappLibDtsOptions, yt as WeappForwardConsoleLogLevel, z as ViteDevServer, zn as GenerateTemplateFileSource, zt as WeappInjectRequestGlobalsTarget } from "./config-
|
|
3
|
+
import { $ as WeappCompilerOutputRequest, $n as NpmPackageFilesConfig, $t as WeappUniAppConfig, A as Ref, An as GenerateDirsOptions, At as WeappAppPreludeConfig, B as BindingErrorLike, Bn as GenerateTemplateInlineSource, Br as WeappViteRuntime, Bt as WeappInjectWeapiConfig, Cn as AliasOptions, Cr as WeappLibVueTscOptions, Ct as AutoImportComponents, D as MethodDefinitions, Dn as CopyGlobs, Dr as WeappManagedSharedTsconfigConfig, Dt as HandleWxmlOptions, E as InlineConfig, En as ChunksConfig, Er as WeappManagedServerTsconfigConfig, Et as EnhanceWxmlOptions, F as RolldownPlugin, Fn as GenerateTemplate, Ft as WeappBuildScopeConfig, G as EntryJsonFragment, Gn as JsonMergeContext, Gt as WeappPreloadNetwork, H as BaseEntry, Hn as GenerateTemplatesConfig, Ht as WeappInjectWebRuntimeGlobalsTarget, I as RolldownPluginOption, In as GenerateTemplateContext, It as WeappBuildScopeObjectConfig, J as ScanComponentItem, Jn as JsonMergeStrategy, Jt as WeappReactConfig, K as PageEntry, Kn as JsonMergeFunction, Kt as WeappPreloadRule, L as RolldownWatchOptions, Ln as GenerateTemplateEntry, Lt as WeappHmrConfig, M as RolldownBuild, Mn as GenerateFileType, Mt as WeappAutoRoutesConfig, N as RolldownOptions, Nn as GenerateFilenamesOptions, Nt as WeappAutoRoutesInclude, O as Plugin, On as CopyOptions, Or as WeappManagedTypeScriptConfig, Ot as MultiPlatformConfig, P as RolldownOutput, Pn as GenerateOptions, Pt as WeappAutoRoutesIncludePattern, Q as WeappCompilerHmrRequest, Qn as NpmMainPackageConfig, Qt as WeappSubPackageConfig, R as RolldownWatcher, Rn as GenerateTemplateFactory, Rt as WeappInjectRequestGlobalsConfig, Sn as Alias, Sr as WeappLibInternalDtsOptions, St as WeappViteConfig, T as ConfigEnv, Tn as BuildNpmPackageMeta, Tr as WeappManagedNodeTsconfigConfig, Tt as EnhanceOptions, U as ComponentEntry, Un as JsFormat, Ut as WeappMcpConfig, V as AppEntry, Vn as GenerateTemplateScope, Vt as WeappInjectWebRuntimeGlobalsConfig, W as Entry, Wn as JsonConfig, Wt as WeappNpmConfig, X as WeappCompilerHmrAsset, Xn as NpmBuildOptions, Xt as WeappRouteRule, Y as WxmlDep, Yn as MpPlatform, Yt as WeappRequestRuntimeConfig, Z as WeappCompilerHmrPreparation, Zn as NpmDependencyPattern, Zt as WeappRouteRules, _n as WxmlTransformNode, _r as WeappLibComponentJson, _t as WeappDebugConfig, an as WxmlRemoveAttrRule, ar as SharedChunkMode, at as WeappCompilerPluginOption, b as ChangeEvent, bn as MultiPlatformProjectConfig, br as WeappLibEntryContext, bt as WeappTailwindcssOptions, cn as WxmlValidationContext, cr as StyleConfigEntry, ct as WeappCompilerSourceClaim, dn as WxmlAttribute, dr as StyleScope, dt as ProjectConfig, en as WeappVueConfig, er as NpmPluginPackageConfig, et as WeappCompilerPlugin, fn as WxmlAttributeValue, fr as SubPackage, ft as SubPackageMetaValue, gn as WxmlTransformContext, gr as SubPackageStyleScope, gt as WeappAnalyzeHistoryConfig, hn as WxmlTransform, hr as SubPackageStyleEntry, ht as WeappAnalyzeConfig, in as WeappWorkerConfig, ir as SharedChunkDynamicImports, it as WeappCompilerPluginFactory, j as ResolvedConfig, jn as GenerateExtensionsOptions, jr as WeappViteHostMeta, jt as WeappAppPreludeMode, k as PluginOption, kn as DeprecatedInlineDynamicImports, kr as WeappWebConfig, kt as ScanWxmlOptions, ln as WxmlValidationDiagnostic, lr as StyleConfigObject, lt as WeappCompilerSourceRequest, mn as WxmlSourceLocation, mr as SubPackageStyleConfigObject, mt as WeappAnalyzeBudgetConfig, nn as WeappWebRuntimeConfig, nr as NpmSubPackageConfig, nt as WeappCompilerPluginContext, on as WxmlRemoveOptions, or as SharedChunkOverride, ot as WeappCompilerPluginPhase, pn as WxmlElementInfo, pr as SubPackageStyleConfigEntry, pt as UserConfig, q as ComponentsMap, qn as JsonMergeStage, qt as WeappReactCompilerConfig, rn as WeappWevuConfig, rr as ResolvedAlias, rt as WeappCompilerPluginController, sn as WxmlValidate, sr as SharedChunkStrategy, st as WeappCompilerResourceKind, tn as WeappVueTemplateConfig, tr as NpmStrategy, tt as WeappCompilerPluginCapabilities, un as WxmlValidationVisitor, ur as StyleEntry, ut as WeappCompilerTransformResult, vn as WxmlTransformResult, vr as WeappLibConfig, vt as WeappForwardConsoleConfig, w as ComputedDefinitions, wn as AlipayNpmMode, wr as WeappManagedAppTsconfigConfig, wt as AutoImportComponentsOption, x as WeappVitePluginApi, xn as MultiPlatformProjectConfigs, xr as WeappLibFileName, xt as WeappUploadConfig, yn as WxmlTransformVisitor, yr as WeappLibDtsOptions, yt as WeappForwardConsoleLogLevel, z as ViteDevServer, zn as GenerateTemplateFileSource, zt as WeappInjectRequestGlobalsTarget } from "./config-BBitSuc3.mjs";
|
|
4
4
|
import { t as WeappI18nConfig } from "./types-e2BMP9NU.mjs";
|
|
5
5
|
export { Alias, AliasOptions, AlipayNpmMode, AppEntry, AutoImportComponents, AutoImportComponentsOption, AutoRoutes, AutoRoutesSubPackage, BaseEntry, BindingErrorLike, BuildNpmPackageMeta, ChangeEvent, ChunksConfig, ComponentEntry, ComponentsMap, type ComputedDefinitions, type ConfigEnv, CopyGlobs, CopyOptions, DeprecatedInlineDynamicImports, EnhanceOptions, EnhanceWxmlOptions, Entry, EntryJsonFragment, GenerateDirsOptions, GenerateExtensionsOptions, GenerateFileType, GenerateFilenamesOptions, GenerateOptions, GenerateTemplate, GenerateTemplateContext, GenerateTemplateEntry, GenerateTemplateFactory, GenerateTemplateFileSource, GenerateTemplateInlineSource, GenerateTemplateScope, GenerateTemplatesConfig, HandleWxmlOptions, type InlineConfig, JsFormat, type JsonConfig, type JsonMergeContext, type JsonMergeFunction, type JsonMergeStage, type JsonMergeStrategy, type MethodDefinitions, MpPlatform, MultiPlatformConfig, MultiPlatformProjectConfig, MultiPlatformProjectConfigs, NpmBuildOptions, NpmDependencyPattern, NpmMainPackageConfig, NpmPackageFilesConfig, NpmPluginPackageConfig, NpmStrategy, NpmSubPackageConfig, PageEntry, type Plugin, type PluginOption, ProjectConfig, type Ref, ResolvedAlias, type ResolvedConfig, type Resolver, type RolldownBuild, type RolldownOptions, type RolldownOutput, type RolldownPlugin, type RolldownPluginOption, type RolldownWatchOptions, type RolldownWatcher, ScanComponentItem, ScanWxmlOptions, SharedChunkDynamicImports, SharedChunkMode, SharedChunkOverride, SharedChunkStrategy, StyleConfigEntry, StyleConfigObject, StyleEntry, StyleScope, SubPackage, SubPackageMetaValue, SubPackageStyleConfigEntry, SubPackageStyleConfigObject, SubPackageStyleEntry, SubPackageStyleScope, UserConfig, type ViteDevServer, WeappAnalyzeBudgetConfig, WeappAnalyzeConfig, WeappAnalyzeHistoryConfig, WeappAppPreludeConfig, WeappAppPreludeMode, WeappAutoRoutesConfig, WeappAutoRoutesInclude, WeappAutoRoutesIncludePattern, WeappBuildScopeConfig, WeappBuildScopeObjectConfig, type WeappCompilerHmrAsset, type WeappCompilerHmrPreparation, type WeappCompilerHmrRequest, WeappCompilerOutputRequest, WeappCompilerPlugin, WeappCompilerPluginCapabilities, WeappCompilerPluginContext, WeappCompilerPluginController, WeappCompilerPluginFactory, WeappCompilerPluginOption, WeappCompilerPluginPhase, WeappCompilerResourceKind, WeappCompilerSourceClaim, WeappCompilerSourceRequest, WeappCompilerTransformResult, WeappDebugConfig, WeappForwardConsoleConfig, WeappForwardConsoleLogLevel, WeappHmrConfig, type WeappI18nConfig, WeappInjectRequestGlobalsConfig, WeappInjectRequestGlobalsTarget, WeappInjectWeapiConfig, WeappInjectWebRuntimeGlobalsConfig, WeappInjectWebRuntimeGlobalsTarget, WeappLibComponentJson, WeappLibConfig, WeappLibDtsOptions, WeappLibEntryContext, WeappLibFileName, WeappLibInternalDtsOptions, WeappLibVueTscOptions, WeappManagedAppTsconfigConfig, WeappManagedNodeTsconfigConfig, WeappManagedServerTsconfigConfig, WeappManagedSharedTsconfigConfig, WeappManagedTypeScriptConfig, WeappMcpConfig, WeappNpmConfig, WeappPreloadNetwork, WeappPreloadRule, WeappReactCompilerConfig, WeappReactConfig, WeappRequestRuntimeConfig, WeappRouteRule, WeappRouteRules, WeappSubPackageConfig, WeappTailwindcssOptions, WeappUniAppConfig, WeappUploadConfig, WeappViteConfig, type WeappViteHostMeta, WeappVitePluginApi, type WeappViteRuntime, WeappVueConfig, WeappVueTemplateConfig, WeappWebConfig, WeappWebRuntimeConfig, WeappWevuConfig, WeappWorkerConfig, WxmlAttribute, WxmlAttributeValue, WxmlDep, WxmlElementInfo, WxmlRemoveAttrRule, WxmlRemoveOptions, WxmlSourceLocation, WxmlTransform, WxmlTransformContext, WxmlTransformNode, WxmlTransformResult, WxmlTransformVisitor, WxmlValidate, WxmlValidationContext, WxmlValidationDiagnostic, WxmlValidationVisitor };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { i as scriptExtensions, s as vueExtensions } from "./constants-BOe8mgqL.mjs";
|
|
2
|
-
import { o as changeFileExtension } from "./file-
|
|
2
|
+
import { o as changeFileExtension } from "./file-gK1WU_h7.mjs";
|
|
3
3
|
import { S as shouldNormalizeUsingComponents, l as getProjectPlatformOptions, p as normalizePlatformNpmImportPath, v as shouldFillComponentGenericsDefault, x as shouldNormalizePlatformNpmImportPath } from "./platform-BiMpsZIb.mjs";
|
|
4
4
|
import { i as normalizeRoot, s as toPosixPath } from "./path-E1OjBJAl.mjs";
|
|
5
5
|
import { n as loadHostRolldownBuild } from "./engine-Mnnm_ALP.mjs";
|
package/dist/vite.d.mts
CHANGED
package/dist/vite.mjs
CHANGED
|
@@ -227,7 +227,7 @@ function weapp() {
|
|
|
227
227
|
...config,
|
|
228
228
|
plugins: serveRequested ? userPlugins : []
|
|
229
229
|
};
|
|
230
|
-
const { WeappBuildSession } = await import("./session-
|
|
230
|
+
const { WeappBuildSession } = await import("./session-D6PfwMgu.mjs");
|
|
231
231
|
session = new WeappBuildSession(takeHostConfigRestartData(inheritedLifecycle, hmrRuntimeSessionKey));
|
|
232
232
|
try {
|
|
233
233
|
const fallbackBeforePrepare = session.hmrRuntimeSession.fallback;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "weapp-vite",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "7.
|
|
4
|
+
"version": "7.11.0-dev.20261112.2",
|
|
5
5
|
"description": "weapp-vite 一个现代化的小程序打包工具",
|
|
6
6
|
"author": "ice breaker <1324318532@qq.com>",
|
|
7
7
|
"license": "MIT",
|
|
@@ -154,7 +154,8 @@
|
|
|
154
154
|
},
|
|
155
155
|
"publishConfig": {
|
|
156
156
|
"access": "public",
|
|
157
|
-
"registry": "https://registry.npmjs.org"
|
|
157
|
+
"registry": "https://registry.npmjs.org/",
|
|
158
|
+
"tag": "snapshot-nightly"
|
|
158
159
|
},
|
|
159
160
|
"peerDependencies": {
|
|
160
161
|
"@vitejs/devtools-kit": "^0.8.0"
|
|
@@ -180,26 +181,26 @@
|
|
|
180
181
|
"@volar/language-service": "^2.4.31",
|
|
181
182
|
"@volar/typescript": "^2.4.31",
|
|
182
183
|
"@vue/language-core": "^3.3.14",
|
|
183
|
-
"@weapp-core/constants": "0.5.
|
|
184
|
-
"@weapp-core/init": "6.1.3",
|
|
185
|
-
"@weapp-core/logger": "3.2.3",
|
|
186
|
-
"@weapp-core/schematics": "6.3.3",
|
|
187
|
-
"@weapp-core/shared": "3.4.3",
|
|
184
|
+
"@weapp-core/constants": "0.5.5-dev.20261112.2",
|
|
185
|
+
"@weapp-core/init": "6.1.3-dev.20261112.2",
|
|
186
|
+
"@weapp-core/logger": "3.2.3-dev.20261112.2",
|
|
187
|
+
"@weapp-core/schematics": "6.3.3-dev.20261112.2",
|
|
188
|
+
"@weapp-core/shared": "3.4.3-dev.20261112.2",
|
|
188
189
|
"@weapp-tailwindcss/engine": "0.1.8",
|
|
189
|
-
"@weapp-vite/acceptance": "0.2.3",
|
|
190
|
-
"@weapp-vite/ast": "7.
|
|
191
|
-
"@weapp-vite/eslint": "0.3.3",
|
|
192
|
-
"@weapp-vite/hmr": "0.3.3",
|
|
193
|
-
"@weapp-vite/i18n": "0.3.
|
|
194
|
-
"@weapp-vite/language-service": "0.1.
|
|
195
|
-
"@weapp-vite/mcp": "2.2.
|
|
196
|
-
"@weapp-vite/miniprogram-automator": "1.5.3",
|
|
197
|
-
"@weapp-vite/tailwindcss": "1.1.3",
|
|
198
|
-
"@weapp-vite/volar": "2.2.3",
|
|
199
|
-
"@weapp-vite/web": "2.2.
|
|
200
|
-
"@weapp-vite/wxml": "0.0.1",
|
|
201
|
-
"@wevu/api": "0.4.3",
|
|
202
|
-
"@wevu/web-apis": "1.5.
|
|
190
|
+
"@weapp-vite/acceptance": "0.2.3-dev.20261112.2",
|
|
191
|
+
"@weapp-vite/ast": "7.11.0-dev.20261112.2",
|
|
192
|
+
"@weapp-vite/eslint": "0.3.3-dev.20261112.2",
|
|
193
|
+
"@weapp-vite/hmr": "0.3.3-dev.20261112.2",
|
|
194
|
+
"@weapp-vite/i18n": "0.3.5-dev.20261112.2",
|
|
195
|
+
"@weapp-vite/language-service": "0.1.4-dev.20261112.2",
|
|
196
|
+
"@weapp-vite/mcp": "2.2.5-dev.20261112.2",
|
|
197
|
+
"@weapp-vite/miniprogram-automator": "1.5.3-dev.20261112.2",
|
|
198
|
+
"@weapp-vite/tailwindcss": "1.1.3-dev.20261112.2",
|
|
199
|
+
"@weapp-vite/volar": "2.2.3-dev.20261112.2",
|
|
200
|
+
"@weapp-vite/web": "2.2.4-dev.20261112.2",
|
|
201
|
+
"@weapp-vite/wxml": "0.0.1-dev.20261112.2",
|
|
202
|
+
"@wevu/api": "0.4.3-dev.20261112.2",
|
|
203
|
+
"@wevu/web-apis": "1.5.1-dev.20261112.2",
|
|
203
204
|
"cac": "^7.1.0",
|
|
204
205
|
"chokidar": "^6.0.0",
|
|
205
206
|
"comment-json": "^5.0.0",
|
|
@@ -225,19 +226,19 @@
|
|
|
225
226
|
"resolve.exports": "2.0.4",
|
|
226
227
|
"rolldown": "1.2.16",
|
|
227
228
|
"rolldown-plugin-dts": "0.30.1",
|
|
228
|
-
"rolldown-require": "2.1.3",
|
|
229
|
+
"rolldown-require": "2.1.3-dev.20261112.2",
|
|
229
230
|
"semver": "^7.8.6",
|
|
230
231
|
"tinyexec": "^1.3.1",
|
|
231
232
|
"typescript": "^6.0.3",
|
|
232
233
|
"vite": "8.3.5",
|
|
233
|
-
"vite-plugin-performance": "2.1.3",
|
|
234
|
+
"vite-plugin-performance": "2.1.3-dev.20261112.2",
|
|
234
235
|
"vite-tsconfig-paths": "^7.0.0-alpha.3",
|
|
235
236
|
"vue": "^3.5.45",
|
|
236
237
|
"vue-eslint-parser": "^10.4.2",
|
|
237
238
|
"vue-tsc": "^3.3.14",
|
|
238
|
-
"weapp-ide-cli": "6.4.
|
|
239
|
+
"weapp-ide-cli": "6.4.4-dev.20261112.2",
|
|
239
240
|
"weapp-tailwindcss": "^5.7.4",
|
|
240
|
-
"wevu": "7.
|
|
241
|
+
"wevu": "7.11.0-dev.20261112.2",
|
|
241
242
|
"zod": "^4.6.7"
|
|
242
243
|
},
|
|
243
244
|
"optionalDependencies": {
|
|
@@ -257,6 +258,13 @@
|
|
|
257
258
|
"tailwindcss": "^4.3.5",
|
|
258
259
|
"ts-morph": "^28.0.0"
|
|
259
260
|
},
|
|
261
|
+
"repoctlSnapshot": {
|
|
262
|
+
"kind": "nightly",
|
|
263
|
+
"commit": "6afc0a3330727030b70967aed33c48b9d59c43b2",
|
|
264
|
+
"buildId": "43276575545-1",
|
|
265
|
+
"identityKey": "d3975aba57991f18ac18c4cffd098ec0e315d194662db4d34ca05ce566d4ef15",
|
|
266
|
+
"tag": "snapshot-nightly"
|
|
267
|
+
},
|
|
260
268
|
"scripts": {
|
|
261
269
|
"dev": "tsdown -w --sourcemap",
|
|
262
270
|
"build": "tsdown",
|
|
@@ -275,4 +283,4 @@
|
|
|
275
283
|
"typecheck": "tsc -p tsconfig.json --noEmit",
|
|
276
284
|
"sync": "repo release sync-npmmirror --package weapp-vite"
|
|
277
285
|
}
|
|
278
|
-
}
|
|
286
|
+
}
|
|
@@ -10,7 +10,9 @@
|
|
|
10
10
|
## 判断
|
|
11
11
|
|
|
12
12
|
- JS/Vue 安全更新:允许在现有 Page、Component 或 wevu 实例上替换并恢复状态。
|
|
13
|
-
-
|
|
13
|
+
- 模板字节、编译后样式、JSON/配置或模块边界不兼容:切换 classic 完整发布,并验证新 runtime、页面节点、样式和交互;本次 dev 会话保持 classic。完整刷新会重置状态,不承诺恢复旧 route/query。
|
|
14
|
+
- 普通编译或业务异常:保留原始诊断及已发布基线,修复后重试,不将执行错误伪装成能力降级。
|
|
15
|
+
- 文件发布、脚本执行确认和 IDE 完整刷新分开判断;旧 build/client 确认不能完成新版本,未连接 IDE 时不宣称 runtime 已更新。
|
|
14
16
|
|
|
15
17
|
## 验收
|
|
16
18
|
|
package/dist/file-WUM9I-Hl.mjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { t as extractConfigFromVue } from "./file-BKX2bE_I.mjs";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { t as getCompilerContext } from "./getInstance-BFOSqiSf.mjs";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { t as loadConfig } from "./loadConfig-DBH8TMJu.mjs";
|