@absolutejs/absolute 0.20.0-beta.44 → 0.20.0-beta.46
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/angular/components/core/streamingSlotRegistrar.js +1 -1
- package/dist/angular/components/core/streamingSlotRegistry.js +2 -2
- package/dist/build.js +143 -124
- package/dist/build.js.map +4 -4
- package/dist/cli/index.js +7679 -7321
- package/dist/index.js +198 -152
- package/dist/index.js.map +6 -6
- package/dist/mobile/browser.js.map +1 -1
- package/dist/mobile/index.js +541 -121
- package/dist/mobile/index.js.map +10 -10
- package/dist/mobile/remoteMacAgentEntry.js +707 -84
- package/dist/mobile/shellExpoAuth.js +20 -41
- package/dist/mobile/shellExpoDevices.js +20 -41
- package/dist/mobile/shellExpoSync.js +104 -0
- package/dist/src/mobile/devDeviceAdapter.d.ts +1 -1
- package/dist/src/mobile/deviceCapabilities.d.ts +4 -2
- package/dist/src/mobile/expoBridge.d.ts +12 -12
- package/dist/src/mobile/nativeAuth.d.ts +3 -0
- package/dist/src/mobile/shellExpoDevices.d.ts +2 -2
- package/dist/src/mobile/shellExpoSync.d.ts +18 -0
- package/package.json +4 -2
package/dist/build.js
CHANGED
|
@@ -12882,10 +12882,11 @@ var isTestSourcePath = (file) => {
|
|
|
12882
12882
|
};
|
|
12883
12883
|
|
|
12884
12884
|
// src/mobile/deviceCapabilities.ts
|
|
12885
|
-
import { readFileSync as readFileSync13 } from "fs";
|
|
12885
|
+
import { existsSync as existsSync20, readFileSync as readFileSync13 } from "fs";
|
|
12886
12886
|
import { extname as extname7, join as join24, relative as relative11, resolve as resolve20 } from "path";
|
|
12887
|
+
import { fileURLToPath as fileURLToPath2 } from "url";
|
|
12887
12888
|
import ts8 from "typescript";
|
|
12888
|
-
var DEVICES_PACKAGE = "@absolutejs/devices",
|
|
12889
|
+
var DEVICES_PACKAGE = "@absolutejs/devices", ADAPTERS, SOURCE_GLOB, IGNORED_DIRECTORIES, IDENTIFIER_PATTERN, providerModulePattern = (provider) => new RegExp(`^@absolutejs/devices-${provider}/[a-z][a-z0-9-]*$`, "u"), providerPackagePattern = (provider) => provider === "capacitor" ? /^@capacitor\/[a-z][a-z0-9-]*@\d+\.\d+\.\d+$/u : /^(?:expo-[a-z][a-z0-9-]*|@react-native-[a-z0-9-]+\/[a-z][a-z0-9-]*)@\d+\.\d+\.\d+$/u, providerLabel = (provider) => provider === "capacitor" ? "Capacitor" : "Expo", ANDROID_PERMISSION_PATTERN, IOS_USAGE_DESCRIPTIONS, IOS_PRIVACY_ACCESSED_API_REASONS, IOS_PRIVACY_ACCESSED_APIS, object = (value) => typeof value === "object" && value !== null && !Array.isArray(value), readJson = (path) => {
|
|
12889
12890
|
const value = JSON.parse(readFileSync13(path, "utf8"));
|
|
12890
12891
|
if (!object(value))
|
|
12891
12892
|
throw new TypeError(`${path} must contain an object.`);
|
|
@@ -12945,7 +12946,7 @@ var DEVICES_PACKAGE = "@absolutejs/devices", CAPACITOR_ADAPTER = "@absolutejs/de
|
|
|
12945
12946
|
...systemBars === true ? { systemBars: true } : {},
|
|
12946
12947
|
...usageDescriptions === undefined ? {} : { usageDescriptions: [...usageDescriptions] }
|
|
12947
12948
|
};
|
|
12948
|
-
}, parseProvider = (name, value) => {
|
|
12949
|
+
}, parseProvider = (name, value, providerName) => {
|
|
12949
12950
|
if (!IDENTIFIER_PATTERN.test(name))
|
|
12950
12951
|
throw new TypeError("Device capability names must be identifiers.");
|
|
12951
12952
|
if (!object(value))
|
|
@@ -12954,10 +12955,13 @@ var DEVICES_PACKAGE = "@absolutejs/devices", CAPACITOR_ADAPTER = "@absolutejs/de
|
|
|
12954
12955
|
const module = text(value.module, `${name}.module`);
|
|
12955
12956
|
if (!IDENTIFIER_PATTERN.test(factory))
|
|
12956
12957
|
throw new TypeError(`${name}.factory must be a JavaScript identifier.`);
|
|
12957
|
-
if (!
|
|
12958
|
-
throw new TypeError(`${name}.module must be an official devices
|
|
12959
|
-
if (!Array.isArray(value.packages) || !value.packages.every((spec) => typeof spec === "string" &&
|
|
12960
|
-
throw new TypeError(`${name}.packages must contain exact official
|
|
12958
|
+
if (!providerModulePattern(providerName).test(module))
|
|
12959
|
+
throw new TypeError(`${name}.module must be an official devices-${providerName} subpath.`);
|
|
12960
|
+
if (!Array.isArray(value.packages) || !value.packages.every((spec) => typeof spec === "string" && providerPackagePattern(providerName).test(spec)))
|
|
12961
|
+
throw new TypeError(`${name}.packages must contain exact official ${providerLabel(providerName)} package versions.`);
|
|
12962
|
+
const { plugins } = value;
|
|
12963
|
+
if (plugins !== undefined && (!Array.isArray(plugins) || !plugins.every((plugin) => typeof plugin === "string" && /^expo-[a-z][a-z0-9-]*$/u.test(plugin))))
|
|
12964
|
+
throw new TypeError(`${name}.plugins must contain Expo config plugin names.`);
|
|
12961
12965
|
let native;
|
|
12962
12966
|
const { native: nativeMetadata } = value;
|
|
12963
12967
|
if (nativeMetadata !== undefined) {
|
|
@@ -12975,6 +12979,7 @@ var DEVICES_PACKAGE = "@absolutejs/devices", CAPACITOR_ADAPTER = "@absolutejs/de
|
|
|
12975
12979
|
factory,
|
|
12976
12980
|
module,
|
|
12977
12981
|
...native === undefined ? {} : { native },
|
|
12982
|
+
...plugins === undefined ? {} : { plugins: [...plugins] },
|
|
12978
12983
|
packages: [...value.packages]
|
|
12979
12984
|
};
|
|
12980
12985
|
}, absoluteDeviceNativeRequirements = (plan) => {
|
|
@@ -13004,18 +13009,27 @@ var DEVICES_PACKAGE = "@absolutejs/devices", CAPACITOR_ADAPTER = "@absolutejs/de
|
|
|
13004
13009
|
...new Set(plan.capabilities.flatMap((name) => plan.providers[name]?.native?.ios?.usageDescriptions ?? []))
|
|
13005
13010
|
].sort()
|
|
13006
13011
|
};
|
|
13007
|
-
}, loadAbsoluteDeviceCapabilityProviders = (projectRoot) => {
|
|
13008
|
-
const
|
|
13012
|
+
}, loadAbsoluteDeviceCapabilityProviders = (projectRoot, provider = "capacitor") => {
|
|
13013
|
+
const adapter = ADAPTERS[provider];
|
|
13014
|
+
let path = join24(resolve20(projectRoot), "node_modules", adapter, "package.json");
|
|
13015
|
+
try {
|
|
13016
|
+
readFileSync13(path, "utf8");
|
|
13017
|
+
} catch {
|
|
13018
|
+
path = fileURLToPath2(import.meta.resolve(`${adapter}/package.json`));
|
|
13019
|
+
}
|
|
13009
13020
|
const manifest = readJson(path);
|
|
13010
13021
|
const { absolutejs } = manifest;
|
|
13011
13022
|
const devices = object(absolutejs) ? absolutejs.devices : undefined;
|
|
13012
|
-
if (!object(devices) || devices.format !== 1 || devices.provider !==
|
|
13013
|
-
throw new TypeError(`${
|
|
13014
|
-
const entries = Object.entries(devices.capabilities).map(([name,
|
|
13023
|
+
if (!object(devices) || devices.format !== 1 || devices.provider !== provider || !object(devices.capabilities))
|
|
13024
|
+
throw new TypeError(`${adapter} does not publish supported capability metadata.`);
|
|
13025
|
+
const entries = Object.entries(devices.capabilities).map(([name, capability]) => ({
|
|
13015
13026
|
name,
|
|
13016
|
-
provider: parseProvider(name, provider)
|
|
13027
|
+
provider: parseProvider(name, capability, provider)
|
|
13017
13028
|
}));
|
|
13018
|
-
return Object.fromEntries(entries.sort((left, right) => left.name.localeCompare(right.name)).map(({ name, provider }) => [
|
|
13029
|
+
return Object.fromEntries(entries.sort((left, right) => left.name.localeCompare(right.name)).map(({ name, provider: capabilityProvider }) => [
|
|
13030
|
+
name,
|
|
13031
|
+
capabilityProvider
|
|
13032
|
+
]));
|
|
13019
13033
|
}, isIgnored = (path) => path.split("/").some((segment) => IGNORED_DIRECTORIES.has(segment)), importedCapabilities = (source, file) => {
|
|
13020
13034
|
const names = new Set;
|
|
13021
13035
|
const namespaces = new Set;
|
|
@@ -13072,6 +13086,8 @@ var DEVICES_PACKAGE = "@absolutejs/devices", CAPACITOR_ADAPTER = "@absolutejs/de
|
|
|
13072
13086
|
return packages;
|
|
13073
13087
|
}, discoverAbsoluteDeviceCapabilities = (projectRoot, providers = loadAbsoluteDeviceCapabilityProviders(projectRoot)) => {
|
|
13074
13088
|
const root = resolve20(projectRoot);
|
|
13089
|
+
if (!existsSync20(root))
|
|
13090
|
+
return [];
|
|
13075
13091
|
const known = new Set(Object.keys(providers));
|
|
13076
13092
|
const capabilities = new Set;
|
|
13077
13093
|
for (const path of SOURCE_GLOB.scanSync({ cwd: root })) {
|
|
@@ -13098,14 +13114,14 @@ var DEVICES_PACKAGE = "@absolutejs/devices", CAPACITOR_ADAPTER = "@absolutejs/de
|
|
|
13098
13114
|
return true;
|
|
13099
13115
|
}
|
|
13100
13116
|
return false;
|
|
13101
|
-
}, resolveAbsoluteDeviceCapabilityPlan = (projectRoot) => {
|
|
13102
|
-
const allProviders = loadAbsoluteDeviceCapabilityProviders(projectRoot);
|
|
13117
|
+
}, resolveAbsoluteDeviceCapabilityPlan = (projectRoot, provider = "capacitor") => {
|
|
13118
|
+
const allProviders = loadAbsoluteDeviceCapabilityProviders(projectRoot, provider);
|
|
13103
13119
|
const capabilities = discoverAbsoluteDeviceCapabilities(projectRoot, allProviders);
|
|
13104
13120
|
const providers = {};
|
|
13105
13121
|
for (const name of capabilities) {
|
|
13106
|
-
const
|
|
13107
|
-
if (
|
|
13108
|
-
providers[name] =
|
|
13122
|
+
const capabilityProvider = allProviders[name];
|
|
13123
|
+
if (capabilityProvider)
|
|
13124
|
+
providers[name] = capabilityProvider;
|
|
13109
13125
|
}
|
|
13110
13126
|
return {
|
|
13111
13127
|
capabilities,
|
|
@@ -13116,6 +13132,10 @@ var DEVICES_PACKAGE = "@absolutejs/devices", CAPACITOR_ADAPTER = "@absolutejs/de
|
|
|
13116
13132
|
};
|
|
13117
13133
|
};
|
|
13118
13134
|
var init_deviceCapabilities = __esm(() => {
|
|
13135
|
+
ADAPTERS = {
|
|
13136
|
+
capacitor: "@absolutejs/devices-capacitor",
|
|
13137
|
+
expo: "@absolutejs/devices-expo"
|
|
13138
|
+
};
|
|
13119
13139
|
SOURCE_GLOB = new Bun.Glob("**/*.{js,jsx,ts,tsx,svelte,vue}");
|
|
13120
13140
|
IGNORED_DIRECTORIES = new Set([
|
|
13121
13141
|
".absolutejs",
|
|
@@ -13129,8 +13149,6 @@ var init_deviceCapabilities = __esm(() => {
|
|
|
13129
13149
|
"tests"
|
|
13130
13150
|
]);
|
|
13131
13151
|
IDENTIFIER_PATTERN = /^[A-Za-z_$][\w$]*$/u;
|
|
13132
|
-
CAPACITOR_MODULE_PATTERN = /^@absolutejs\/devices-capacitor\/[a-z][a-z0-9-]*$/u;
|
|
13133
|
-
CAPACITOR_PACKAGE_PATTERN = /^@capacitor\/[a-z][a-z0-9-]*@\d+\.\d+\.\d+$/u;
|
|
13134
13152
|
ANDROID_PERMISSION_PATTERN = /^android\.permission\.[A-Z][A-Z0-9_]*$/u;
|
|
13135
13153
|
IOS_USAGE_DESCRIPTIONS = new Set([
|
|
13136
13154
|
"camera",
|
|
@@ -13148,7 +13166,7 @@ var init_deviceCapabilities = __esm(() => {
|
|
|
13148
13166
|
});
|
|
13149
13167
|
|
|
13150
13168
|
// node_modules/@absolutejs/sync/dist/client/index.js
|
|
13151
|
-
var RUNTIME_TRANSPORT, host, isRegistry = (value) => typeof value === "object" && value !== null && Array.isArray(Reflect.get(value, "installations")) && Array.isArray(Reflect.get(value, "clients")), registry, SyncLocalDataPolicyError, SyncLocalStoreSchemaError, positiveVersion = (value, label) => {
|
|
13169
|
+
var RUNTIME_TRANSPORT, host, isRegistry = (value) => typeof value === "object" && value !== null && Array.isArray(Reflect.get(value, "installations")) && Array.isArray(Reflect.get(value, "clients")), registry, pools, SyncLocalDataPolicyError, SyncLocalStoreSchemaError, positiveVersion = (value, label) => {
|
|
13152
13170
|
if (!Number.isSafeInteger(value) || value < 1)
|
|
13153
13171
|
throw new SyncLocalStoreSchemaError("INVALID_PLAN", `${label} must be a positive safe integer`);
|
|
13154
13172
|
return value;
|
|
@@ -13253,6 +13271,7 @@ var init_client = __esm(() => {
|
|
|
13253
13271
|
});
|
|
13254
13272
|
return created;
|
|
13255
13273
|
})();
|
|
13274
|
+
pools = new Map;
|
|
13256
13275
|
SyncLocalDataPolicyError = class SyncLocalDataPolicyError extends Error {
|
|
13257
13276
|
code;
|
|
13258
13277
|
constructor(code, message) {
|
|
@@ -14141,7 +14160,7 @@ var exports_parseAngularConfigImports = {};
|
|
|
14141
14160
|
__export(exports_parseAngularConfigImports, {
|
|
14142
14161
|
parseAngularProvidersImport: () => parseAngularProvidersImport
|
|
14143
14162
|
});
|
|
14144
|
-
import { existsSync as
|
|
14163
|
+
import { existsSync as existsSync21, readFileSync as readFileSync18 } from "fs";
|
|
14145
14164
|
import { dirname as dirname15, isAbsolute as isAbsolute3, join as join30 } from "path";
|
|
14146
14165
|
import ts12 from "typescript";
|
|
14147
14166
|
var findDefineConfigCall = (sf) => {
|
|
@@ -14198,7 +14217,7 @@ var findDefineConfigCall = (sf) => {
|
|
|
14198
14217
|
const envOverride = process.env.ABSOLUTE_CONFIG;
|
|
14199
14218
|
if (envOverride) {
|
|
14200
14219
|
const resolved = isAbsolute3(envOverride) ? envOverride : join30(projectRoot, envOverride);
|
|
14201
|
-
if (
|
|
14220
|
+
if (existsSync21(resolved))
|
|
14202
14221
|
return resolved;
|
|
14203
14222
|
}
|
|
14204
14223
|
const candidates = [
|
|
@@ -14208,7 +14227,7 @@ var findDefineConfigCall = (sf) => {
|
|
|
14208
14227
|
join30(projectRoot, "absolute.config.mjs")
|
|
14209
14228
|
];
|
|
14210
14229
|
for (const candidate of candidates) {
|
|
14211
|
-
if (
|
|
14230
|
+
if (existsSync21(candidate))
|
|
14212
14231
|
return candidate;
|
|
14213
14232
|
}
|
|
14214
14233
|
return null;
|
|
@@ -14386,7 +14405,7 @@ __export(exports_compileSvelte, {
|
|
|
14386
14405
|
clearSvelteCompilerCache: () => clearSvelteCompilerCache,
|
|
14387
14406
|
compileSvelte: () => compileSvelte
|
|
14388
14407
|
});
|
|
14389
|
-
import { existsSync as
|
|
14408
|
+
import { existsSync as existsSync22 } from "fs";
|
|
14390
14409
|
import { mkdir as mkdir6, stat as stat2 } from "fs/promises";
|
|
14391
14410
|
import {
|
|
14392
14411
|
dirname as dirname16,
|
|
@@ -14402,11 +14421,11 @@ var {write: write2, file, Transpiler: Transpiler2 } = globalThis.Bun;
|
|
|
14402
14421
|
var resolveDevClientDir2 = () => {
|
|
14403
14422
|
const projectRoot = process.cwd();
|
|
14404
14423
|
const fromSource = resolve22(import.meta.dir, "../dev/client");
|
|
14405
|
-
if (
|
|
14424
|
+
if (existsSync22(fromSource) && fromSource.startsWith(projectRoot)) {
|
|
14406
14425
|
return fromSource;
|
|
14407
14426
|
}
|
|
14408
14427
|
const fromNodeModules = resolve22(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
|
|
14409
|
-
if (
|
|
14428
|
+
if (existsSync22(fromNodeModules))
|
|
14410
14429
|
return fromNodeModules;
|
|
14411
14430
|
return resolve22(import.meta.dir, "./dev/client");
|
|
14412
14431
|
}, devClientDir2, hmrClientPath3, persistentCache, sourceHashCache, clearSvelteCompilerCache = () => {
|
|
@@ -14509,7 +14528,7 @@ var resolveDevClientDir2 = () => {
|
|
|
14509
14528
|
const contentHash = Bun.hash(raw).toString(BASE_36_RADIX);
|
|
14510
14529
|
const prevHash = sourceHashCache.get(src);
|
|
14511
14530
|
const persistent = persistentCache.get(src);
|
|
14512
|
-
if (prevHash === contentHash && persistent &&
|
|
14531
|
+
if (prevHash === contentHash && persistent && existsSync22(persistent.ssr) && existsSync22(persistent.client)) {
|
|
14513
14532
|
cache.set(src, persistent);
|
|
14514
14533
|
return persistent;
|
|
14515
14534
|
}
|
|
@@ -15231,7 +15250,7 @@ __export(exports_compileVue, {
|
|
|
15231
15250
|
generateVueHmrId: () => generateVueHmrId,
|
|
15232
15251
|
vueHmrMetadata: () => vueHmrMetadata
|
|
15233
15252
|
});
|
|
15234
|
-
import { existsSync as
|
|
15253
|
+
import { existsSync as existsSync23, readFileSync as readFileSync20, realpathSync as realpathSync2 } from "fs";
|
|
15235
15254
|
import { mkdir as mkdir7 } from "fs/promises";
|
|
15236
15255
|
import {
|
|
15237
15256
|
basename as basename11,
|
|
@@ -15245,11 +15264,11 @@ var {file: file2, write: write3, Transpiler: Transpiler3 } = globalThis.Bun;
|
|
|
15245
15264
|
var resolveDevClientDir3 = () => {
|
|
15246
15265
|
const projectRoot = process.cwd();
|
|
15247
15266
|
const fromSource = resolve23(import.meta.dir, "../dev/client");
|
|
15248
|
-
if (
|
|
15267
|
+
if (existsSync23(fromSource) && fromSource.startsWith(projectRoot)) {
|
|
15249
15268
|
return fromSource;
|
|
15250
15269
|
}
|
|
15251
15270
|
const fromNodeModules = resolve23(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
|
|
15252
|
-
if (
|
|
15271
|
+
if (existsSync23(fromNodeModules))
|
|
15253
15272
|
return fromNodeModules;
|
|
15254
15273
|
return resolve23(import.meta.dir, "./dev/client");
|
|
15255
15274
|
}, devClientDir3, hmrClientPath4, transpiler4, scriptCache, scriptSetupCache, templateCache, styleCache, persistentBuildCache, vueSourceHashCache, vueHmrMetadata, clearVueHmrCaches = () => {
|
|
@@ -15302,7 +15321,7 @@ var resolveDevClientDir3 = () => {
|
|
|
15302
15321
|
const importRegex = /@import\s+(?:url\(\s*)?(['"])(\.{1,2}\/[^'"]+)\1\s*\)?\s*;?/g;
|
|
15303
15322
|
return cssContent.replace(importRegex, (match, _quote, relPath) => {
|
|
15304
15323
|
const importedPath = resolve23(dirname17(cssFilePath), relPath);
|
|
15305
|
-
if (!
|
|
15324
|
+
if (!existsSync23(importedPath))
|
|
15306
15325
|
return match;
|
|
15307
15326
|
const importedContent = readFileSync20(importedPath, "utf-8");
|
|
15308
15327
|
return inlineCssImports(importedContent, importedPath, visited);
|
|
@@ -15311,10 +15330,10 @@ var resolveDevClientDir3 = () => {
|
|
|
15311
15330
|
if (helper.endsWith(".ts"))
|
|
15312
15331
|
return resolve23(sourceDir, helper);
|
|
15313
15332
|
const direct = resolve23(sourceDir, `${helper}.ts`);
|
|
15314
|
-
if (
|
|
15333
|
+
if (existsSync23(direct))
|
|
15315
15334
|
return direct;
|
|
15316
15335
|
const indexed = resolve23(sourceDir, helper, "index.ts");
|
|
15317
|
-
if (
|
|
15336
|
+
if (existsSync23(indexed))
|
|
15318
15337
|
return indexed;
|
|
15319
15338
|
return direct;
|
|
15320
15339
|
}, toJs = (filePath, sourceDir) => {
|
|
@@ -15330,10 +15349,10 @@ var resolveDevClientDir3 = () => {
|
|
|
15330
15349
|
}
|
|
15331
15350
|
if (sourceDir && (filePath.startsWith("./") || filePath.startsWith("../"))) {
|
|
15332
15351
|
const directTs = resolve23(sourceDir, `${filePath}.ts`);
|
|
15333
|
-
if (
|
|
15352
|
+
if (existsSync23(directTs))
|
|
15334
15353
|
return `${filePath}.js`;
|
|
15335
15354
|
const indexedTs = resolve23(sourceDir, filePath, "index.ts");
|
|
15336
|
-
if (
|
|
15355
|
+
if (existsSync23(indexedTs))
|
|
15337
15356
|
return `${filePath}/index.js`;
|
|
15338
15357
|
}
|
|
15339
15358
|
return `${filePath}.js`;
|
|
@@ -15394,7 +15413,7 @@ const ${localName} = (source) => ${importedName}(
|
|
|
15394
15413
|
const contentHash = Bun.hash(sourceContent).toString(BASE_36_RADIX);
|
|
15395
15414
|
const prevHash = vueSourceHashCache.get(sourceFilePath);
|
|
15396
15415
|
const persistent = persistentBuildCache.get(sourceFilePath);
|
|
15397
|
-
if (prevHash === contentHash && persistent &&
|
|
15416
|
+
if (prevHash === contentHash && persistent && existsSync23(persistent.clientPath) && existsSync23(persistent.serverPath)) {
|
|
15398
15417
|
cacheMap.set(sourceFilePath, persistent);
|
|
15399
15418
|
return persistent;
|
|
15400
15419
|
}
|
|
@@ -15434,8 +15453,8 @@ const ${localName} = (source) => ${importedName}(
|
|
|
15434
15453
|
const hasScript = descriptor.script || descriptor.scriptSetup;
|
|
15435
15454
|
const compiledScript = hasScript ? compiler.compileScript(descriptor, {
|
|
15436
15455
|
fs: {
|
|
15437
|
-
fileExists:
|
|
15438
|
-
readFile: (file3) =>
|
|
15456
|
+
fileExists: existsSync23,
|
|
15457
|
+
readFile: (file3) => existsSync23(file3) ? readFileSync20(file3, "utf-8") : undefined,
|
|
15439
15458
|
realpath: realpathSync2
|
|
15440
15459
|
},
|
|
15441
15460
|
id: componentId,
|
|
@@ -15597,7 +15616,7 @@ if (typeof __VUE_HMR_RUNTIME__ !== 'undefined') {
|
|
|
15597
15616
|
const routes = parseVueSpaRoutes(descriptor.script?.content ?? "");
|
|
15598
15617
|
for (const { importPath } of routes) {
|
|
15599
15618
|
const childPath = resolve23(dirname17(entryPath), importPath);
|
|
15600
|
-
if (expanded.has(childPath) || !
|
|
15619
|
+
if (expanded.has(childPath) || !existsSync23(childPath)) {
|
|
15601
15620
|
continue;
|
|
15602
15621
|
}
|
|
15603
15622
|
expanded.add(childPath);
|
|
@@ -15803,7 +15822,7 @@ if (typeof __VUE_HMR_RUNTIME__ !== 'undefined') {
|
|
|
15803
15822
|
continue;
|
|
15804
15823
|
}
|
|
15805
15824
|
const resolved = resolveHelperTsPath(helperDir, dep);
|
|
15806
|
-
if (!
|
|
15825
|
+
if (!existsSync23(resolved))
|
|
15807
15826
|
continue;
|
|
15808
15827
|
if (allTsHelperPaths.has(resolved))
|
|
15809
15828
|
continue;
|
|
@@ -16330,7 +16349,7 @@ __export(exports_compileAngular, {
|
|
|
16330
16349
|
compileAngularFiles: () => compileAngularFiles,
|
|
16331
16350
|
invalidateAngularJitCache: () => invalidateAngularJitCache
|
|
16332
16351
|
});
|
|
16333
|
-
import { existsSync as
|
|
16352
|
+
import { existsSync as existsSync24, readFileSync as readFileSync21, promises as fs5 } from "fs";
|
|
16334
16353
|
import { join as join33, basename as basename12, sep as sep3, dirname as dirname18, resolve as resolve24, relative as relative14 } from "path";
|
|
16335
16354
|
var {Glob: Glob6 } = globalThis.Bun;
|
|
16336
16355
|
import ts14 from "typescript";
|
|
@@ -16387,7 +16406,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
|
|
|
16387
16406
|
join33(candidate, "index.js"),
|
|
16388
16407
|
join33(candidate, "index.jsx")
|
|
16389
16408
|
];
|
|
16390
|
-
return candidates.find((file3) =>
|
|
16409
|
+
return candidates.find((file3) => existsSync24(file3));
|
|
16391
16410
|
}, createLegacyAngularAnimationUsageResolver = (rootDir) => {
|
|
16392
16411
|
const baseDir = resolve24(rootDir);
|
|
16393
16412
|
const tsconfigAliases = readTsconfigPathAliases();
|
|
@@ -16468,11 +16487,11 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
|
|
|
16468
16487
|
}, resolveDevClientDir4 = () => {
|
|
16469
16488
|
const projectRoot = process.cwd();
|
|
16470
16489
|
const fromSource = resolve24(import.meta.dir, "../dev/client");
|
|
16471
|
-
if (
|
|
16490
|
+
if (existsSync24(fromSource) && fromSource.startsWith(projectRoot)) {
|
|
16472
16491
|
return fromSource;
|
|
16473
16492
|
}
|
|
16474
16493
|
const fromNodeModules = resolve24(projectRoot, "node_modules/@absolutejs/absolute/dist/dev/client");
|
|
16475
|
-
if (
|
|
16494
|
+
if (existsSync24(fromNodeModules))
|
|
16476
16495
|
return fromNodeModules;
|
|
16477
16496
|
return resolve24(import.meta.dir, "./dev/client");
|
|
16478
16497
|
}, devClientDir4, hmrClientPath5, formatDiagnosticMessage = (diagnostic) => {
|
|
@@ -16518,11 +16537,11 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
|
|
|
16518
16537
|
return `${path}${query}`;
|
|
16519
16538
|
const importerDir = dirname18(importerOutputPath);
|
|
16520
16539
|
const fileCandidate = resolve24(importerDir, `${path}.js`);
|
|
16521
|
-
if (outputFiles?.has(fileCandidate) ||
|
|
16540
|
+
if (outputFiles?.has(fileCandidate) || existsSync24(fileCandidate)) {
|
|
16522
16541
|
return `${path}.js${query}`;
|
|
16523
16542
|
}
|
|
16524
16543
|
const indexCandidate = resolve24(importerDir, path, "index.js");
|
|
16525
|
-
if (outputFiles?.has(indexCandidate) ||
|
|
16544
|
+
if (outputFiles?.has(indexCandidate) || existsSync24(indexCandidate)) {
|
|
16526
16545
|
return `${path}/index.js${query}`;
|
|
16527
16546
|
}
|
|
16528
16547
|
return `${path}.js${query}`;
|
|
@@ -16560,7 +16579,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
|
|
|
16560
16579
|
join33(basePath, "index.mts"),
|
|
16561
16580
|
join33(basePath, "index.cts")
|
|
16562
16581
|
];
|
|
16563
|
-
return candidates.map((candidate) => resolve24(candidate)).find((candidate) =>
|
|
16582
|
+
return candidates.map((candidate) => resolve24(candidate)).find((candidate) => existsSync24(candidate) && !candidate.endsWith(".d.ts")) ?? null;
|
|
16564
16583
|
}, readFileForAotTransform = async (fileName, readFile6) => {
|
|
16565
16584
|
const hostSource = readFile6?.(fileName);
|
|
16566
16585
|
if (typeof hostSource === "string")
|
|
@@ -16641,7 +16660,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
|
|
|
16641
16660
|
if (visited.has(resolvedPath))
|
|
16642
16661
|
return;
|
|
16643
16662
|
visited.add(resolvedPath);
|
|
16644
|
-
if (!
|
|
16663
|
+
if (!existsSync24(resolvedPath) || resolvedPath.endsWith(".d.ts"))
|
|
16645
16664
|
return;
|
|
16646
16665
|
stats.filesVisited += 1;
|
|
16647
16666
|
const source = await readFileForAotTransform(resolvedPath, readFile6);
|
|
@@ -16815,7 +16834,7 @@ var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) =>
|
|
|
16815
16834
|
return null;
|
|
16816
16835
|
}, resolveAngularDeferImportSpecifier = () => {
|
|
16817
16836
|
const sourceEntry = resolve24(import.meta.dir, "../angular/components/index.ts");
|
|
16818
|
-
if (
|
|
16837
|
+
if (existsSync24(sourceEntry)) {
|
|
16819
16838
|
return sourceEntry.replace(/\\/g, "/");
|
|
16820
16839
|
}
|
|
16821
16840
|
return "@absolutejs/absolute/angular/components";
|
|
@@ -16943,7 +16962,7 @@ ${slot.resolvedBindings.map((binding) => ` "${binding.key}": this.__absoluteDef
|
|
|
16943
16962
|
${fields}
|
|
16944
16963
|
`);
|
|
16945
16964
|
}, readAndEscapeFile = async (filePath, stylePreprocessors) => {
|
|
16946
|
-
if (!
|
|
16965
|
+
if (!existsSync24(filePath)) {
|
|
16947
16966
|
throw new Error(`Unable to inline Angular style resource: file not found at ${filePath}`);
|
|
16948
16967
|
}
|
|
16949
16968
|
const content = await compileStyleFileIfNeeded(filePath, stylePreprocessors);
|
|
@@ -16952,7 +16971,7 @@ ${fields}
|
|
|
16952
16971
|
const templateUrlMatch = findUncommentedMatch(source, /templateUrl\s*:\s*['"]([^'"]+)['"]/);
|
|
16953
16972
|
if (templateUrlMatch?.[1]) {
|
|
16954
16973
|
const templatePath = join33(fileDir, templateUrlMatch[1]);
|
|
16955
|
-
if (!
|
|
16974
|
+
if (!existsSync24(templatePath)) {
|
|
16956
16975
|
throw new Error(`Unable to inline Angular templateUrl "${templateUrlMatch[1]}": file not found at ${templatePath}`);
|
|
16957
16976
|
}
|
|
16958
16977
|
const templateRaw2 = await fs5.readFile(templatePath, "utf-8");
|
|
@@ -16983,7 +17002,7 @@ ${fields}
|
|
|
16983
17002
|
const templateUrlMatch = findUncommentedMatch(source, /templateUrl\s*:\s*['"]([^'"]+)['"]/);
|
|
16984
17003
|
if (templateUrlMatch?.[1]) {
|
|
16985
17004
|
const templatePath = join33(fileDir, templateUrlMatch[1]);
|
|
16986
|
-
if (!
|
|
17005
|
+
if (!existsSync24(templatePath)) {
|
|
16987
17006
|
throw new Error(`Unable to inline Angular templateUrl "${templateUrlMatch[1]}": file not found at ${templatePath}`);
|
|
16988
17007
|
}
|
|
16989
17008
|
const templateRaw2 = readFileSync21(templatePath, "utf-8");
|
|
@@ -17131,7 +17150,7 @@ ${fields}
|
|
|
17131
17150
|
join33(candidate, "index.js"),
|
|
17132
17151
|
join33(candidate, "index.jsx")
|
|
17133
17152
|
];
|
|
17134
|
-
return candidates.find((file3) =>
|
|
17153
|
+
return candidates.find((file3) => existsSync24(file3));
|
|
17135
17154
|
};
|
|
17136
17155
|
const resolveLocalImport = (specifier, fromDir) => {
|
|
17137
17156
|
if (specifier.startsWith(".") || specifier.startsWith("/")) {
|
|
@@ -17206,7 +17225,7 @@ ${fields}
|
|
|
17206
17225
|
if (visited.has(resolved))
|
|
17207
17226
|
return;
|
|
17208
17227
|
visited.add(resolved);
|
|
17209
|
-
if (resolved.endsWith(".json") &&
|
|
17228
|
+
if (resolved.endsWith(".json") && existsSync24(resolved)) {
|
|
17210
17229
|
const inputDir2 = dirname18(resolved);
|
|
17211
17230
|
const relativeDir2 = inputDir2.startsWith(baseDir) ? inputDir2.substring(baseDir.length + 1) : inputDir2;
|
|
17212
17231
|
const targetDir2 = join33(outDir, relativeDir2);
|
|
@@ -17219,7 +17238,7 @@ ${fields}
|
|
|
17219
17238
|
let actualPath = resolved;
|
|
17220
17239
|
if (!actualPath.endsWith(".ts"))
|
|
17221
17240
|
actualPath += ".ts";
|
|
17222
|
-
if (!
|
|
17241
|
+
if (!existsSync24(actualPath))
|
|
17223
17242
|
return;
|
|
17224
17243
|
let sourceCode = await fs5.readFile(actualPath, "utf-8");
|
|
17225
17244
|
const inlined = await inlineResources(sourceCode, dirname18(actualPath), stylePreprocessors);
|
|
@@ -17257,7 +17276,7 @@ ${fields}
|
|
|
17257
17276
|
const isEntry = resolve24(actualPath) === resolve24(entryPath);
|
|
17258
17277
|
const contentHash = Bun.hash(sourceCode).toString(BASE_36_RADIX);
|
|
17259
17278
|
const cacheKey2 = actualPath;
|
|
17260
|
-
const shouldWriteFile = cacheBuster && isEntry ? true : jitContentCache.get(cacheKey2) !== contentHash || !
|
|
17279
|
+
const shouldWriteFile = cacheBuster && isEntry ? true : jitContentCache.get(cacheKey2) !== contentHash || !existsSync24(targetPath);
|
|
17261
17280
|
if (shouldWriteFile) {
|
|
17262
17281
|
const processedContent = transpileAndRewrite(sourceCode, relativeDir, actualPath, importRewrites);
|
|
17263
17282
|
const preservedInjection = await readPreservedInjection(targetPath);
|
|
@@ -17270,7 +17289,7 @@ ${fields}
|
|
|
17270
17289
|
};
|
|
17271
17290
|
await transpileFile(inputPath);
|
|
17272
17291
|
const entryOutputPath = toOutputPath(entryPath);
|
|
17273
|
-
if (
|
|
17292
|
+
if (existsSync24(entryOutputPath)) {
|
|
17274
17293
|
const entryOutput = await fs5.readFile(entryOutputPath, "utf-8");
|
|
17275
17294
|
const withoutLegacyFlag = entryOutput.replace(/\nexport const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;\n?/g, `
|
|
17276
17295
|
`);
|
|
@@ -17296,7 +17315,7 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
|
|
|
17296
17315
|
await traceAngularPhase("aot/copy-json-resources", async () => {
|
|
17297
17316
|
const cwd = process.cwd();
|
|
17298
17317
|
const angularSrcDir = resolve24(outRoot);
|
|
17299
|
-
if (!
|
|
17318
|
+
if (!existsSync24(angularSrcDir))
|
|
17300
17319
|
return;
|
|
17301
17320
|
const jsonGlob = new Glob6("**/*.json");
|
|
17302
17321
|
for (const rel of jsonGlob.scanSync({
|
|
@@ -17331,15 +17350,15 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
|
|
|
17331
17350
|
...candidatePaths.map((file3) => resolve24(file3)),
|
|
17332
17351
|
...compiledFallbackPaths
|
|
17333
17352
|
];
|
|
17334
|
-
let candidate = normalizedCandidates.find((file3) =>
|
|
17353
|
+
let candidate = normalizedCandidates.find((file3) => existsSync24(file3) && file3.endsWith(`${sep3}${relativeEntry}`));
|
|
17335
17354
|
if (!candidate) {
|
|
17336
|
-
candidate = normalizedCandidates.find((file3) =>
|
|
17355
|
+
candidate = normalizedCandidates.find((file3) => existsSync24(file3) && file3.endsWith(`${sep3}pages${sep3}${jsName}`));
|
|
17337
17356
|
}
|
|
17338
17357
|
if (!candidate) {
|
|
17339
|
-
candidate = normalizedCandidates.find((file3) =>
|
|
17358
|
+
candidate = normalizedCandidates.find((file3) => existsSync24(file3) && file3.endsWith(`${sep3}${jsName}`));
|
|
17340
17359
|
}
|
|
17341
17360
|
if (!candidate) {
|
|
17342
|
-
candidate = normalizedCandidates.find((file3) =>
|
|
17361
|
+
candidate = normalizedCandidates.find((file3) => existsSync24(file3));
|
|
17343
17362
|
}
|
|
17344
17363
|
return candidate;
|
|
17345
17364
|
};
|
|
@@ -17347,11 +17366,11 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
|
|
|
17347
17366
|
if (!rawServerFile) {
|
|
17348
17367
|
rawServerFile = await traceAngularPhase("wrapper/resolve-server-output-fallback", () => resolveRawServerFile([]), { entry: resolvedEntry });
|
|
17349
17368
|
}
|
|
17350
|
-
if (rawServerFile && !
|
|
17369
|
+
if (rawServerFile && !existsSync24(rawServerFile)) {
|
|
17351
17370
|
outputs = hmr ? await compileEntry() : aotOutputs;
|
|
17352
17371
|
rawServerFile = await traceAngularPhase("wrapper/resolve-server-output-retry", () => resolveRawServerFile(outputs), { entry: resolvedEntry });
|
|
17353
17372
|
}
|
|
17354
|
-
if (!rawServerFile || !
|
|
17373
|
+
if (!rawServerFile || !existsSync24(rawServerFile)) {
|
|
17355
17374
|
throw new Error(`Compiled output not found for ${entry}. Looking for: ${jsName}. Available: ${[
|
|
17356
17375
|
...outputs,
|
|
17357
17376
|
...compiledFallbackPaths
|
|
@@ -17387,7 +17406,7 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
|
|
|
17387
17406
|
const serverContentHash = `${Bun.hash(original).toString(BASE_36_RADIX)}.${Bun.hash(providersHashInput).toString(BASE_36_RADIX)}`;
|
|
17388
17407
|
const cachedWrapper = wrapperOutputCache.get(resolvedEntry);
|
|
17389
17408
|
const clientFile = join33(indexesDir, jsName);
|
|
17390
|
-
if (hmr && cachedWrapper && cachedWrapper.serverHash === serverContentHash &&
|
|
17409
|
+
if (hmr && cachedWrapper && cachedWrapper.serverHash === serverContentHash && existsSync24(clientFile) && (usesLegacyAnimations || !original.includes("__ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__")) && (!usesLegacyAnimations || original.includes("__ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__"))) {
|
|
17391
17410
|
return {
|
|
17392
17411
|
clientPath: clientFile,
|
|
17393
17412
|
indexUnchanged: true,
|
|
@@ -18392,7 +18411,7 @@ __export(exports_fastHmrCompiler, {
|
|
|
18392
18411
|
takePendingModule: () => takePendingModule,
|
|
18393
18412
|
tryFastHmr: () => tryFastHmr
|
|
18394
18413
|
});
|
|
18395
|
-
import { existsSync as
|
|
18414
|
+
import { existsSync as existsSync25, readFileSync as readFileSync22, statSync as statSync2 } from "fs";
|
|
18396
18415
|
import { dirname as dirname19, extname as extname9, relative as relative15, resolve as resolve25 } from "path";
|
|
18397
18416
|
import ts18 from "typescript";
|
|
18398
18417
|
var fail = (reason, detail, location) => ({
|
|
@@ -18716,7 +18735,7 @@ var fail = (reason, detail, location) => ({
|
|
|
18716
18735
|
`${base}/index.tsx`
|
|
18717
18736
|
];
|
|
18718
18737
|
for (const candidate of candidates) {
|
|
18719
|
-
if (!
|
|
18738
|
+
if (!existsSync25(candidate))
|
|
18720
18739
|
continue;
|
|
18721
18740
|
let content;
|
|
18722
18741
|
try {
|
|
@@ -19481,7 +19500,7 @@ var fail = (reason, detail, location) => ({
|
|
|
19481
19500
|
if (visited.has(startDtsPath))
|
|
19482
19501
|
return null;
|
|
19483
19502
|
visited.add(startDtsPath);
|
|
19484
|
-
if (!
|
|
19503
|
+
if (!existsSync25(startDtsPath))
|
|
19485
19504
|
return null;
|
|
19486
19505
|
let content;
|
|
19487
19506
|
try {
|
|
@@ -19534,16 +19553,16 @@ var fail = (reason, detail, location) => ({
|
|
|
19534
19553
|
`${base}/index.d.cts`
|
|
19535
19554
|
];
|
|
19536
19555
|
for (const c of candidates) {
|
|
19537
|
-
if (
|
|
19556
|
+
if (existsSync25(c))
|
|
19538
19557
|
return c;
|
|
19539
19558
|
}
|
|
19540
19559
|
return null;
|
|
19541
19560
|
}, findPackageDtsForJs = (jsPath) => {
|
|
19542
19561
|
const sibling = jsPath.replace(/\.[mc]?js$/, ".d.ts");
|
|
19543
|
-
if (
|
|
19562
|
+
if (existsSync25(sibling))
|
|
19544
19563
|
return sibling;
|
|
19545
19564
|
const mirror = jsPath.replace(/\/dist\//, "/dist/src/").replace(/\.[mc]?js$/, ".d.ts");
|
|
19546
|
-
if (
|
|
19565
|
+
if (existsSync25(mirror))
|
|
19547
19566
|
return mirror;
|
|
19548
19567
|
return null;
|
|
19549
19568
|
}, resolveChildComponentInfo = (className, spec, componentDir, projectRoot) => {
|
|
@@ -19556,7 +19575,7 @@ var fail = (reason, detail, location) => ({
|
|
|
19556
19575
|
`${base}/index.tsx`
|
|
19557
19576
|
];
|
|
19558
19577
|
for (const candidate of candidates) {
|
|
19559
|
-
if (!
|
|
19578
|
+
if (!existsSync25(candidate))
|
|
19560
19579
|
continue;
|
|
19561
19580
|
const info = getChildComponentInfoFromTsSource(candidate, className);
|
|
19562
19581
|
if (info)
|
|
@@ -19770,11 +19789,11 @@ var fail = (reason, detail, location) => ({
|
|
|
19770
19789
|
const resolved = resolve25(componentDir, spec);
|
|
19771
19790
|
for (const ext of TS_EXTENSIONS) {
|
|
19772
19791
|
const candidate = resolved + ext;
|
|
19773
|
-
if (
|
|
19792
|
+
if (existsSync25(candidate))
|
|
19774
19793
|
return candidate;
|
|
19775
19794
|
}
|
|
19776
19795
|
const indexCandidate = resolve25(resolved, "index.ts");
|
|
19777
|
-
if (
|
|
19796
|
+
if (existsSync25(indexCandidate))
|
|
19778
19797
|
return indexCandidate;
|
|
19779
19798
|
}
|
|
19780
19799
|
return null;
|
|
@@ -20012,7 +20031,7 @@ ${transpiled}
|
|
|
20012
20031
|
}${staticPatch}`;
|
|
20013
20032
|
}, STYLE_PREPROCESSED_EXT, resolveAndReadStyleResource = (componentDir, url) => {
|
|
20014
20033
|
const abs = resolve25(componentDir, url);
|
|
20015
|
-
if (!
|
|
20034
|
+
if (!existsSync25(abs))
|
|
20016
20035
|
return null;
|
|
20017
20036
|
const ext = extname9(abs).toLowerCase();
|
|
20018
20037
|
if (!STYLE_PREPROCESSED_EXT.has(ext) || ext === ".css") {
|
|
@@ -20052,7 +20071,7 @@ ${block}
|
|
|
20052
20071
|
return cached;
|
|
20053
20072
|
const tsconfigPath = resolve25(projectRoot, "tsconfig.json");
|
|
20054
20073
|
const opts = {};
|
|
20055
|
-
if (
|
|
20074
|
+
if (existsSync25(tsconfigPath)) {
|
|
20056
20075
|
try {
|
|
20057
20076
|
const text2 = readFileSync22(tsconfigPath, "utf8");
|
|
20058
20077
|
const parsed = ts18.parseConfigFileTextToJson(tsconfigPath, text2);
|
|
@@ -20079,7 +20098,7 @@ ${block}
|
|
|
20079
20098
|
}, tryFastHmr = async (params) => {
|
|
20080
20099
|
const { componentFilePath, className } = params;
|
|
20081
20100
|
const projectRoot = params.projectRoot ?? process.cwd();
|
|
20082
|
-
if (!
|
|
20101
|
+
if (!existsSync25(componentFilePath)) {
|
|
20083
20102
|
return fail("file-not-found", componentFilePath);
|
|
20084
20103
|
}
|
|
20085
20104
|
let compiler;
|
|
@@ -20135,7 +20154,7 @@ ${block}
|
|
|
20135
20154
|
templatePath = componentFilePath;
|
|
20136
20155
|
} else if (decoratorMeta.templateUrl) {
|
|
20137
20156
|
const tplAbs = resolve25(componentDir, decoratorMeta.templateUrl);
|
|
20138
|
-
if (!
|
|
20157
|
+
if (!existsSync25(tplAbs)) {
|
|
20139
20158
|
return fail("template-resource-not-found", `Template file not found: ${tplAbs}`, { file: componentFilePath });
|
|
20140
20159
|
}
|
|
20141
20160
|
templateText = readFileSync22(tplAbs, "utf8");
|
|
@@ -20904,7 +20923,7 @@ __export(exports_compileEmber, {
|
|
|
20904
20923
|
getEmberCompiledRoot: () => getEmberCompiledRoot,
|
|
20905
20924
|
getEmberServerCompiledDir: () => getEmberServerCompiledDir
|
|
20906
20925
|
});
|
|
20907
|
-
import { existsSync as
|
|
20926
|
+
import { existsSync as existsSync26 } from "fs";
|
|
20908
20927
|
import { mkdir as mkdir8, rm as rm5 } from "fs/promises";
|
|
20909
20928
|
import { basename as basename13, dirname as dirname20, extname as extname10, join as join34, resolve as resolve26 } from "path";
|
|
20910
20929
|
var {build: bunBuild2, Transpiler: Transpiler4, write: write4, file: file3 } = globalThis.Bun;
|
|
@@ -21006,7 +21025,7 @@ export const importSync = (specifier) => {
|
|
|
21006
21025
|
const extensionsToTry = ["", ".gts", ".gjs", ".ts", ".js"];
|
|
21007
21026
|
for (const ext of extensionsToTry) {
|
|
21008
21027
|
const candidate = candidateBase + ext;
|
|
21009
|
-
if (
|
|
21028
|
+
if (existsSync26(candidate))
|
|
21010
21029
|
return { path: candidate };
|
|
21011
21030
|
}
|
|
21012
21031
|
return;
|
|
@@ -21026,7 +21045,7 @@ export const importSync = (specifier) => {
|
|
|
21026
21045
|
if (standalonePackages.has(args.path))
|
|
21027
21046
|
return;
|
|
21028
21047
|
const internal = join34(cwd, "node_modules/ember-source/dist/packages", args.path, "index.js");
|
|
21029
|
-
if (
|
|
21048
|
+
if (existsSync26(internal))
|
|
21030
21049
|
return { path: internal };
|
|
21031
21050
|
return;
|
|
21032
21051
|
});
|
|
@@ -21156,7 +21175,7 @@ __export(exports_buildReactVendor, {
|
|
|
21156
21175
|
buildReactVendor: () => buildReactVendor,
|
|
21157
21176
|
computeVendorPaths: () => computeVendorPaths
|
|
21158
21177
|
});
|
|
21159
|
-
import { existsSync as
|
|
21178
|
+
import { existsSync as existsSync27, mkdirSync as mkdirSync8 } from "fs";
|
|
21160
21179
|
import { join as join35, resolve as resolve27 } from "path";
|
|
21161
21180
|
import { rm as rm6 } from "fs/promises";
|
|
21162
21181
|
var {build: bunBuild3 } = globalThis.Bun;
|
|
@@ -21170,7 +21189,7 @@ var resolveJsxDevRuntimeCompatPath = () => {
|
|
|
21170
21189
|
resolve27(import.meta.dir, "..", "..", "src", "react", "jsxDevRuntimeCompat.ts")
|
|
21171
21190
|
];
|
|
21172
21191
|
for (const candidate of candidates) {
|
|
21173
|
-
if (
|
|
21192
|
+
if (existsSync27(candidate)) {
|
|
21174
21193
|
return candidate.replace(/\\/g, "/");
|
|
21175
21194
|
}
|
|
21176
21195
|
}
|
|
@@ -21637,7 +21656,7 @@ var init_buildSvelteVendor = __esm(() => {
|
|
|
21637
21656
|
import {
|
|
21638
21657
|
copyFileSync as copyFileSync2,
|
|
21639
21658
|
cpSync,
|
|
21640
|
-
existsSync as
|
|
21659
|
+
existsSync as existsSync28,
|
|
21641
21660
|
mkdirSync as mkdirSync12,
|
|
21642
21661
|
readdirSync as readdirSync5,
|
|
21643
21662
|
readFileSync as readFileSync23,
|
|
@@ -21870,7 +21889,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
|
|
|
21870
21889
|
copyVueDevIndexes(vueDir, vuePagesPath, vueEntries, devIndexDir);
|
|
21871
21890
|
}
|
|
21872
21891
|
}, copyReactDevIndexes = (reactIndexesPath, reactPagesPath, devIndexDir, readDir) => {
|
|
21873
|
-
if (!
|
|
21892
|
+
if (!existsSync28(reactIndexesPath)) {
|
|
21874
21893
|
return;
|
|
21875
21894
|
}
|
|
21876
21895
|
const indexFiles = readDir(reactIndexesPath).filter((file4) => file4.endsWith(".tsx"));
|
|
@@ -21886,7 +21905,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
|
|
|
21886
21905
|
for (const entry of sveltePageEntries) {
|
|
21887
21906
|
const name = basename14(entry).replace(/\.svelte(\.(ts|js))?$/, "");
|
|
21888
21907
|
const indexFile = join39(svelteIndexDir, "pages", `${name}.js`);
|
|
21889
|
-
if (!
|
|
21908
|
+
if (!existsSync28(indexFile))
|
|
21890
21909
|
continue;
|
|
21891
21910
|
let content = readFileSync23(indexFile, "utf-8");
|
|
21892
21911
|
const srcRel = relative16(process.cwd(), resolve28(entry)).replace(/\\/g, "/");
|
|
@@ -21899,7 +21918,7 @@ ${offenders.map((o3) => ` \u2022 ${o3}`).join(`
|
|
|
21899
21918
|
for (const entry of vuePageEntries) {
|
|
21900
21919
|
const name = basename14(entry, ".vue");
|
|
21901
21920
|
const indexFile = join39(vueIndexDir, `${name}.js`);
|
|
21902
|
-
if (!
|
|
21921
|
+
if (!existsSync28(indexFile))
|
|
21903
21922
|
continue;
|
|
21904
21923
|
let content = readFileSync23(indexFile, "utf-8");
|
|
21905
21924
|
const srcRel = relative16(process.cwd(), resolve28(entry)).replace(/\\/g, "/");
|
|
@@ -23143,7 +23162,7 @@ ${content.slice(firstUseIdx)}`;
|
|
|
23143
23162
|
}
|
|
23144
23163
|
if (!hmr) {
|
|
23145
23164
|
const reactVendorDir = join39(buildPath, "react", "vendor");
|
|
23146
|
-
const vendorChunkPaths =
|
|
23165
|
+
const vendorChunkPaths = existsSync28(reactVendorDir) ? [
|
|
23147
23166
|
...new Glob8("**/*.js").scanSync({
|
|
23148
23167
|
absolute: true,
|
|
23149
23168
|
cwd: reactVendorDir
|
|
@@ -23569,7 +23588,7 @@ var init_build = __esm(() => {
|
|
|
23569
23588
|
});
|
|
23570
23589
|
|
|
23571
23590
|
// src/build/buildEmberVendor.ts
|
|
23572
|
-
import { mkdirSync as mkdirSync13, existsSync as
|
|
23591
|
+
import { mkdirSync as mkdirSync13, existsSync as existsSync29 } from "fs";
|
|
23573
23592
|
import { join as join40 } from "path";
|
|
23574
23593
|
import { rm as rm10 } from "fs/promises";
|
|
23575
23594
|
var {build: bunBuild8 } = globalThis.Bun;
|
|
@@ -23623,7 +23642,7 @@ export const importSync = (specifier) => {
|
|
|
23623
23642
|
return { resolveTo: specifier, specifier };
|
|
23624
23643
|
}
|
|
23625
23644
|
const emberInternalPath = join40(cwd2, "node_modules/ember-source/dist/packages", specifier, "index.js");
|
|
23626
|
-
if (!
|
|
23645
|
+
if (!existsSync29(emberInternalPath)) {
|
|
23627
23646
|
throw new Error(`Ember vendor build: cannot find ${specifier} at ${emberInternalPath}. ` + `Is ember-source installed and at least 6.12?`);
|
|
23628
23647
|
}
|
|
23629
23648
|
return { resolveTo: emberInternalPath, specifier };
|
|
@@ -23655,7 +23674,7 @@ export const importSync = (specifier) => {
|
|
|
23655
23674
|
return;
|
|
23656
23675
|
}
|
|
23657
23676
|
const internal = join40(cwd2, "node_modules/ember-source/dist/packages", args.path, "index.js");
|
|
23658
|
-
if (
|
|
23677
|
+
if (existsSync29(internal)) {
|
|
23659
23678
|
return { path: internal };
|
|
23660
23679
|
}
|
|
23661
23680
|
return;
|
|
@@ -23827,7 +23846,7 @@ __export(exports_dependencyGraph, {
|
|
|
23827
23846
|
getAffectedFiles: () => getAffectedFiles,
|
|
23828
23847
|
removeFileFromGraph: () => removeFileFromGraph
|
|
23829
23848
|
});
|
|
23830
|
-
import { existsSync as
|
|
23849
|
+
import { existsSync as existsSync30, readFileSync as readFileSync24 } from "fs";
|
|
23831
23850
|
var {Glob: Glob9 } = globalThis.Bun;
|
|
23832
23851
|
import { resolve as resolve29 } from "path";
|
|
23833
23852
|
var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath) => {
|
|
@@ -23857,10 +23876,10 @@ var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath)
|
|
|
23857
23876
|
];
|
|
23858
23877
|
for (const ext of extensions) {
|
|
23859
23878
|
const withExt = normalized + ext;
|
|
23860
|
-
if (
|
|
23879
|
+
if (existsSync30(withExt))
|
|
23861
23880
|
return withExt;
|
|
23862
23881
|
}
|
|
23863
|
-
if (
|
|
23882
|
+
if (existsSync30(normalized))
|
|
23864
23883
|
return normalized;
|
|
23865
23884
|
return null;
|
|
23866
23885
|
}, clearExistingDependents = (graph, normalizedPath) => {
|
|
@@ -23875,7 +23894,7 @@ var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath)
|
|
|
23875
23894
|
}
|
|
23876
23895
|
}, addFileToGraph = (graph, filePath) => {
|
|
23877
23896
|
const normalizedPath = resolve29(filePath);
|
|
23878
|
-
if (!
|
|
23897
|
+
if (!existsSync30(normalizedPath))
|
|
23879
23898
|
return;
|
|
23880
23899
|
const dependencies = extractDependencies(normalizedPath);
|
|
23881
23900
|
clearExistingDependents(graph, normalizedPath);
|
|
@@ -23901,7 +23920,7 @@ var emptyDependencyGraph, tsTranspiler, jsTranspiler, loaderForFile = (filePath)
|
|
|
23901
23920
|
}, IGNORED_SEGMENTS, buildInitialDependencyGraph = (graph, directories) => {
|
|
23902
23921
|
const processedFiles = new Set;
|
|
23903
23922
|
const glob = new Glob9("**/*.{ts,tsx,js,jsx,vue,svelte,html,htm}");
|
|
23904
|
-
const resolvedDirs = directories.map((dir) => resolve29(dir)).filter((dir) =>
|
|
23923
|
+
const resolvedDirs = directories.map((dir) => resolve29(dir)).filter((dir) => existsSync30(dir));
|
|
23905
23924
|
const allFiles = resolvedDirs.flatMap((dir) => Array.from(glob.scanSync({ absolute: true, cwd: dir })));
|
|
23906
23925
|
for (const file4 of allFiles) {
|
|
23907
23926
|
const fullPath = resolve29(file4);
|
|
@@ -24155,7 +24174,7 @@ var init_clientManager = __esm(() => {
|
|
|
24155
24174
|
});
|
|
24156
24175
|
|
|
24157
24176
|
// src/dev/pathUtils.ts
|
|
24158
|
-
import { existsSync as
|
|
24177
|
+
import { existsSync as existsSync31, readdirSync as readdirSync6, readFileSync as readFileSync25 } from "fs";
|
|
24159
24178
|
import { dirname as dirname22, resolve as resolve31 } from "path";
|
|
24160
24179
|
var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
|
|
24161
24180
|
if (shouldIgnorePath(filePath, resolved)) {
|
|
@@ -24329,7 +24348,7 @@ var STYLE_EXTENSION_PATTERN2, detectFramework = (filePath, resolved) => {
|
|
|
24329
24348
|
push(cfg.stylesDir);
|
|
24330
24349
|
for (const candidate of ["src", "db", "assets", "styles"]) {
|
|
24331
24350
|
const abs = normalizePath(resolve31(cwd2, candidate));
|
|
24332
|
-
if (
|
|
24351
|
+
if (existsSync31(abs) && !roots.includes(abs))
|
|
24333
24352
|
roots.push(abs);
|
|
24334
24353
|
}
|
|
24335
24354
|
try {
|
|
@@ -24422,7 +24441,7 @@ var init_pathUtils = __esm(() => {
|
|
|
24422
24441
|
|
|
24423
24442
|
// src/dev/fileWatcher.ts
|
|
24424
24443
|
import { watch } from "fs";
|
|
24425
|
-
import { existsSync as
|
|
24444
|
+
import { existsSync as existsSync32, readdirSync as readdirSync7, statSync as statSync4 } from "fs";
|
|
24426
24445
|
import { dirname as dirname23, join as join41, resolve as resolve32 } from "path";
|
|
24427
24446
|
var safeRemoveFromGraph = (graph, fullPath) => {
|
|
24428
24447
|
try {
|
|
@@ -24489,12 +24508,12 @@ var safeRemoveFromGraph = (graph, fullPath) => {
|
|
|
24489
24508
|
if (shouldIgnorePath(fullPath, state.resolvedPaths)) {
|
|
24490
24509
|
return;
|
|
24491
24510
|
}
|
|
24492
|
-
if (event === "rename" && !
|
|
24511
|
+
if (event === "rename" && !existsSync32(fullPath)) {
|
|
24493
24512
|
safeRemoveFromGraph(state.dependencyGraph, fullPath);
|
|
24494
24513
|
onFileChange(fullPath);
|
|
24495
24514
|
return;
|
|
24496
24515
|
}
|
|
24497
|
-
if (
|
|
24516
|
+
if (existsSync32(fullPath)) {
|
|
24498
24517
|
onFileChange(fullPath);
|
|
24499
24518
|
safeAddToGraph(state.dependencyGraph, fullPath);
|
|
24500
24519
|
}
|
|
@@ -24504,7 +24523,7 @@ var safeRemoveFromGraph = (graph, fullPath) => {
|
|
|
24504
24523
|
const stylesDir = state.resolvedPaths?.stylesDir;
|
|
24505
24524
|
paths.forEach((path) => {
|
|
24506
24525
|
const absolutePath = resolve32(path).replace(/\\/g, "/");
|
|
24507
|
-
if (!
|
|
24526
|
+
if (!existsSync32(absolutePath)) {
|
|
24508
24527
|
return;
|
|
24509
24528
|
}
|
|
24510
24529
|
const isStylesDir = Boolean(stylesDir && absolutePath.startsWith(stylesDir));
|
|
@@ -24515,7 +24534,7 @@ var safeRemoveFromGraph = (graph, fullPath) => {
|
|
|
24515
24534
|
const stylesDir = state.resolvedPaths?.stylesDir;
|
|
24516
24535
|
watchPaths.forEach((path) => {
|
|
24517
24536
|
const absolutePath = resolve32(path).replace(/\\/g, "/");
|
|
24518
|
-
if (!
|
|
24537
|
+
if (!existsSync32(absolutePath)) {
|
|
24519
24538
|
return;
|
|
24520
24539
|
}
|
|
24521
24540
|
const isStylesDir = Boolean(stylesDir && absolutePath.startsWith(stylesDir));
|
|
@@ -25659,7 +25678,7 @@ __export(exports_moduleServer, {
|
|
|
25659
25678
|
warmCompilers: () => warmCompilers,
|
|
25660
25679
|
warnIfReactFastRefreshUnsupported: () => warnIfReactFastRefreshUnsupported
|
|
25661
25680
|
});
|
|
25662
|
-
import { existsSync as
|
|
25681
|
+
import { existsSync as existsSync33, readFileSync as readFileSync29, realpathSync as realpathSync3, statSync as statSync6 } from "fs";
|
|
25663
25682
|
import { basename as basename16, dirname as dirname27, extname as extname13, join as join43, resolve as resolve40, relative as relative17 } from "path";
|
|
25664
25683
|
var SRC_PREFIX = "/@src/", BROWSER_DEFINE, jsTranspiler2, legacyDecoratorTsconfig, tsTranspiler2, tsxTranspiler, TRANSPILABLE, ALL_EXPORTS_RE, STRING_CONTENTS_RE, preserveTypeExports = (originalSource, transpiled, valueExports) => {
|
|
25665
25684
|
const codeOnly = originalSource.replace(STRING_CONTENTS_RE, '""');
|
|
@@ -25680,10 +25699,10 @@ var SRC_PREFIX = "/@src/", BROWSER_DEFINE, jsTranspiler2, legacyDecoratorTsconfi
|
|
|
25680
25699
|
${stubs}
|
|
25681
25700
|
`;
|
|
25682
25701
|
}, resolveRelativeExtension = (srcPath, projectRoot, extensions) => {
|
|
25683
|
-
const directHit = extensions.find((ext) =>
|
|
25702
|
+
const directHit = extensions.find((ext) => existsSync33(resolve40(projectRoot, srcPath + ext)));
|
|
25684
25703
|
if (directHit)
|
|
25685
25704
|
return srcPath + directHit;
|
|
25686
|
-
const indexHit = extensions.find((ext) =>
|
|
25705
|
+
const indexHit = extensions.find((ext) => existsSync33(resolve40(projectRoot, srcPath, `index${ext}`)));
|
|
25687
25706
|
if (indexHit)
|
|
25688
25707
|
return `${srcPath}/index${indexHit}`;
|
|
25689
25708
|
return srcPath;
|
|
@@ -25744,12 +25763,12 @@ ${stubs}
|
|
|
25744
25763
|
if (!subpath) {
|
|
25745
25764
|
const pkgDir = resolve40(projectRoot, "node_modules", packageName ?? "");
|
|
25746
25765
|
const pkgJsonPath = join43(pkgDir, "package.json");
|
|
25747
|
-
if (
|
|
25766
|
+
if (existsSync33(pkgJsonPath)) {
|
|
25748
25767
|
const pkg = JSON.parse(readFileSync29(pkgJsonPath, "utf-8"));
|
|
25749
25768
|
const esmEntry = typeof pkg.module === "string" && pkg.module || typeof pkg.browser === "string" && pkg.browser;
|
|
25750
25769
|
if (esmEntry) {
|
|
25751
25770
|
const resolved = resolve40(pkgDir, esmEntry);
|
|
25752
|
-
if (
|
|
25771
|
+
if (existsSync33(resolved))
|
|
25753
25772
|
return relative17(projectRoot, resolved);
|
|
25754
25773
|
}
|
|
25755
25774
|
}
|
|
@@ -26111,9 +26130,9 @@ ${code}`;
|
|
|
26111
26130
|
const hasScript = descriptor.script || descriptor.scriptSetup;
|
|
26112
26131
|
const compiledScript = hasScript ? vueCompiler.compileScript(descriptor, {
|
|
26113
26132
|
fs: {
|
|
26114
|
-
fileExists:
|
|
26133
|
+
fileExists: existsSync33,
|
|
26115
26134
|
realpath: realpathSync3,
|
|
26116
|
-
readFile: (file4) =>
|
|
26135
|
+
readFile: (file4) => existsSync33(file4) ? readFileSync29(file4, "utf-8") : undefined
|
|
26117
26136
|
},
|
|
26118
26137
|
id: componentId,
|
|
26119
26138
|
inlineTemplate: false
|
|
@@ -26143,11 +26162,11 @@ ${code}`;
|
|
|
26143
26162
|
`);
|
|
26144
26163
|
return result;
|
|
26145
26164
|
}, resolveSvelteModulePath = (path) => {
|
|
26146
|
-
if (
|
|
26165
|
+
if (existsSync33(path))
|
|
26147
26166
|
return path;
|
|
26148
|
-
if (
|
|
26167
|
+
if (existsSync33(`${path}.ts`))
|
|
26149
26168
|
return `${path}.ts`;
|
|
26150
|
-
if (
|
|
26169
|
+
if (existsSync33(`${path}.js`))
|
|
26151
26170
|
return `${path}.js`;
|
|
26152
26171
|
return path;
|
|
26153
26172
|
}, jsResponse = (body) => {
|
|
@@ -26298,7 +26317,7 @@ export default {};
|
|
|
26298
26317
|
return { ext, filePath: resolveSvelteModulePath(filePath) };
|
|
26299
26318
|
if (ext)
|
|
26300
26319
|
return { ext, filePath };
|
|
26301
|
-
const found = MODULE_EXTENSIONS.find((candidate) =>
|
|
26320
|
+
const found = MODULE_EXTENSIONS.find((candidate) => existsSync33(filePath + candidate));
|
|
26302
26321
|
if (!found)
|
|
26303
26322
|
return { ext, filePath };
|
|
26304
26323
|
const resolved = filePath + found;
|
|
@@ -26883,7 +26902,7 @@ var handleHTMXUpdate = async (htmxFilePath) => {
|
|
|
26883
26902
|
var init_simpleHTMXHMR = () => {};
|
|
26884
26903
|
|
|
26885
26904
|
// src/dev/rebuildTrigger.ts
|
|
26886
|
-
import { existsSync as
|
|
26905
|
+
import { existsSync as existsSync34, readdirSync as readdirSync9, rmSync as rmSync3 } from "fs";
|
|
26887
26906
|
import {
|
|
26888
26907
|
basename as basename17,
|
|
26889
26908
|
dirname as dirname29,
|
|
@@ -26997,7 +27016,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
|
|
|
26997
27016
|
detectedFw = detected !== "ignored" ? detected : affectedFrameworks[0];
|
|
26998
27017
|
}
|
|
26999
27018
|
return { ...parsed, framework: detectedFw };
|
|
27000
|
-
}, isValidDeletedAffectedFile = (affectedFile, deletedPathResolved, processedFiles) => affectedFile !== deletedPathResolved && !processedFiles.has(affectedFile) &&
|
|
27019
|
+
}, isValidDeletedAffectedFile = (affectedFile, deletedPathResolved, processedFiles) => affectedFile !== deletedPathResolved && !processedFiles.has(affectedFile) && existsSync34(affectedFile), FRAMEWORK_DIR_KEYS_FOR_CLEANUP, removeStaleGenerated = (state, deletedFile) => {
|
|
27001
27020
|
const { config } = state;
|
|
27002
27021
|
const cwd2 = process.cwd();
|
|
27003
27022
|
const absDeleted = resolvePath(deletedFile).replace(/\\/g, "/");
|
|
@@ -27043,7 +27062,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
|
|
|
27043
27062
|
if (!dependents || dependents.size === 0) {
|
|
27044
27063
|
return;
|
|
27045
27064
|
}
|
|
27046
|
-
const dependentFiles = Array.from(dependents).filter((file4) =>
|
|
27065
|
+
const dependentFiles = Array.from(dependents).filter((file4) => existsSync34(file4));
|
|
27047
27066
|
if (dependentFiles.length === 0) {
|
|
27048
27067
|
return;
|
|
27049
27068
|
}
|
|
@@ -27059,7 +27078,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
|
|
|
27059
27078
|
try {
|
|
27060
27079
|
const affectedFiles = getAffectedFiles(state.dependencyGraph, normalizedFilePath);
|
|
27061
27080
|
affectedFiles.forEach((affectedFile) => {
|
|
27062
|
-
if (!processedFiles.has(affectedFile) && affectedFile !== normalizedFilePath &&
|
|
27081
|
+
if (!processedFiles.has(affectedFile) && affectedFile !== normalizedFilePath && existsSync34(affectedFile)) {
|
|
27063
27082
|
validFiles.push(affectedFile);
|
|
27064
27083
|
processedFiles.add(affectedFile);
|
|
27065
27084
|
}
|
|
@@ -27084,7 +27103,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
|
|
|
27084
27103
|
collectChangedFileAffected(state, normalizedFilePath, processedFiles, validFiles);
|
|
27085
27104
|
}, processFilePathSet = (state, filePathSet, processedFiles, validFiles) => {
|
|
27086
27105
|
filePathSet.forEach((filePathInSet) => {
|
|
27087
|
-
if (!
|
|
27106
|
+
if (!existsSync34(filePathInSet)) {
|
|
27088
27107
|
collectDeletedFileAffected(state, filePathInSet, processedFiles, validFiles);
|
|
27089
27108
|
return;
|
|
27090
27109
|
}
|
|
@@ -27349,7 +27368,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
|
|
|
27349
27368
|
return componentFile;
|
|
27350
27369
|
}
|
|
27351
27370
|
const tsCounterpart = componentFile.replace(/\.html$/, ".ts");
|
|
27352
|
-
if (
|
|
27371
|
+
if (existsSync34(tsCounterpart)) {
|
|
27353
27372
|
return tsCounterpart;
|
|
27354
27373
|
}
|
|
27355
27374
|
if (!graph)
|
|
@@ -28219,7 +28238,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, clearDevSs
|
|
|
28219
28238
|
}
|
|
28220
28239
|
return ctx;
|
|
28221
28240
|
}, runSvelteBundleRebuild = async (state, svelteFiles, config) => {
|
|
28222
|
-
const existingSvelteFiles = svelteFiles.filter((file4) =>
|
|
28241
|
+
const existingSvelteFiles = svelteFiles.filter((file4) => existsSync34(file4));
|
|
28223
28242
|
if (existingSvelteFiles.length === 0)
|
|
28224
28243
|
return;
|
|
28225
28244
|
const svelteDir = config.svelteDirectory ?? "";
|
|
@@ -30382,5 +30401,5 @@ export {
|
|
|
30382
30401
|
devBuild
|
|
30383
30402
|
};
|
|
30384
30403
|
|
|
30385
|
-
//# debugId=
|
|
30404
|
+
//# debugId=3CE370EE4B6900BE64756E2164756E21
|
|
30386
30405
|
//# sourceMappingURL=build.js.map
|