@absolutejs/absolute 0.19.0-beta.1134 → 0.19.0-beta.1136

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/index.js CHANGED
@@ -24442,7 +24442,11 @@ var resolveDevClientDir3 = () => {
24442
24442
  return "template-only";
24443
24443
  }
24444
24444
  return "full";
24445
- }, generateVueHmrId = (sourceFilePath, vueRootDir) => relative12(vueRootDir, sourceFilePath).replace(/\\/g, "/").replace(/\.vue$/, ""), extractImports = (sourceCode) => Array.from(sourceCode.matchAll(/import\s+[\s\S]+?['"]([^'"]+)['"]/g)).map((match) => match[1]).filter((importPath) => importPath !== undefined), inlineCssImports = (cssContent, cssFilePath, visited = new Set) => {
24445
+ }, generateVueHmrId = (sourceFilePath, vueRootDir) => relative12(vueRootDir, sourceFilePath).replace(/\\/g, "/").replace(/\.vue$/, ""), extractImports = (sourceCode) => {
24446
+ const staticImports = Array.from(sourceCode.matchAll(/import\s+[\s\S]+?['"]([^'"]+)['"]/g));
24447
+ const dynamicImports = Array.from(sourceCode.matchAll(/\bimport\s*\(\s*['"]([^'"]+)['"]\s*\)/g));
24448
+ return Array.from(new Set([...staticImports, ...dynamicImports].map((match) => match[1]).filter((importPath) => importPath !== undefined)));
24449
+ }, inlineCssImports = (cssContent, cssFilePath, visited = new Set) => {
24446
24450
  const resolved = realpathSync2(cssFilePath);
24447
24451
  if (visited.has(resolved))
24448
24452
  return "";
@@ -34436,7 +34440,7 @@ __export(exports_moduleServer, {
34436
34440
  });
34437
34441
  import { existsSync as existsSync35, readFileSync as readFileSync30, realpathSync as realpathSync3, statSync as statSync6 } from "fs";
34438
34442
  import { basename as basename16, dirname as dirname26, extname as extname12, join as join44, resolve as resolve39, relative as relative16 } from "path";
34439
- var SRC_PREFIX = "/@src/", jsTranspiler2, legacyDecoratorTsconfig, tsTranspiler2, tsxTranspiler, TRANSPILABLE, ALL_EXPORTS_RE, STRING_CONTENTS_RE, preserveTypeExports = (originalSource, transpiled, valueExports) => {
34443
+ var SRC_PREFIX = "/@src/", jsTranspiler2, legacyDecoratorTsconfig, tsTranspiler2, tsxTranspiler, TRANSPILABLE, NODE_MODULES_SEGMENT, PREBUILT_EXTENSIONS, ESM_SYNTAX, isPrebuiltDependencyModule = (filePath, ext, raw) => PREBUILT_EXTENSIONS.has(ext) && NODE_MODULES_SEGMENT.test(filePath) && ESM_SYNTAX.test(raw), ALL_EXPORTS_RE, STRING_CONTENTS_RE, preserveTypeExports = (originalSource, transpiled, valueExports) => {
34440
34444
  const codeOnly = originalSource.replace(STRING_CONTENTS_RE, '""');
34441
34445
  const allExports = [];
34442
34446
  let match;
@@ -34647,6 +34651,9 @@ ${transpiled}`;
34647
34651
  const ext = extname12(filePath);
34648
34652
  const isTS = ext === ".ts" || ext === ".tsx";
34649
34653
  const isTSX = ext === ".tsx" || ext === ".jsx";
34654
+ if (isPrebuiltDependencyModule(filePath, ext, raw)) {
34655
+ return rewriteImports(raw, filePath, projectRoot, rewriter);
34656
+ }
34650
34657
  let transpiler6 = jsTranspiler2;
34651
34658
  if (isTSX)
34652
34659
  transpiler6 = tsxTranspiler;
@@ -35267,6 +35274,9 @@ var init_moduleServer = __esm(() => {
35267
35274
  tsconfig: legacyDecoratorTsconfig
35268
35275
  });
35269
35276
  TRANSPILABLE = new Set([".ts", ".tsx", ".js", ".jsx", ".mjs"]);
35277
+ NODE_MODULES_SEGMENT = /[/\\]node_modules[/\\]/u;
35278
+ PREBUILT_EXTENSIONS = new Set([".js", ".mjs"]);
35279
+ ESM_SYNTAX = /^\s*(?:import|export)[\s{*("']/mu;
35270
35280
  ALL_EXPORTS_RE = /export\s+(?:type|interface|const|let|var|function|class|enum|abstract\s+class)\s+(\w+)/g;
35271
35281
  STRING_CONTENTS_RE = /`(?:[^`\\]|\\.)*`|'(?:[^'\\]|\\.)*'|"(?:[^"\\]|\\.)*"/gs;
35272
35282
  IMPORT_EXTENSIONS = [".tsx", ".ts", ".jsx", ".js", ".svelte", ".vue"];
@@ -48053,5 +48063,5 @@ export {
48053
48063
  ANGULAR_INIT_TIMEOUT_MS
48054
48064
  };
48055
48065
 
48056
- //# debugId=82221892868C9F1E64756E2164756E21
48066
+ //# debugId=98865C7DD5E9991F64756E2164756E21
48057
48067
  //# sourceMappingURL=index.js.map