@absolutejs/absolute 0.19.0-beta.780 → 0.19.0-beta.782
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/build.js +11 -4
- package/dist/build.js.map +3 -3
- package/dist/cli/index.js +59 -0
- package/dist/index.js +11 -4
- package/dist/index.js.map +3 -3
- package/package.json +1 -1
package/dist/build.js
CHANGED
|
@@ -10095,11 +10095,17 @@ var resolveDevClientDir3 = () => {
|
|
|
10095
10095
|
return "template-only";
|
|
10096
10096
|
}
|
|
10097
10097
|
return "full";
|
|
10098
|
-
}, generateVueHmrId = (sourceFilePath, vueRootDir) => relative8(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), toJs = (filePath) => {
|
|
10098
|
+
}, generateVueHmrId = (sourceFilePath, vueRootDir) => relative8(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), toJs = (filePath, sourceDir) => {
|
|
10099
10099
|
if (filePath.endsWith(".vue"))
|
|
10100
10100
|
return filePath.replace(/\.vue$/, ".js");
|
|
10101
10101
|
if (filePath.endsWith(".ts"))
|
|
10102
10102
|
return filePath.replace(/\.ts$/, ".js");
|
|
10103
|
+
if (isStylePath(filePath)) {
|
|
10104
|
+
if (sourceDir && (filePath.startsWith("./") || filePath.startsWith("../"))) {
|
|
10105
|
+
return resolve15(sourceDir, filePath);
|
|
10106
|
+
}
|
|
10107
|
+
return filePath;
|
|
10108
|
+
}
|
|
10103
10109
|
return `${filePath}.js`;
|
|
10104
10110
|
}, stripExports = (code) => code.replace(/export\s+default/, "const script =").replace(/^export\s+/gm, ""), mergeVueImports = (code) => {
|
|
10105
10111
|
const lines = code.split(`
|
|
@@ -10165,7 +10171,8 @@ var resolveDevClientDir3 = () => {
|
|
|
10165
10171
|
inlineTemplate: false
|
|
10166
10172
|
}) : { bindings: {}, content: "export default {};" };
|
|
10167
10173
|
const strippedScript = stripExports(compiledScript.content);
|
|
10168
|
-
const
|
|
10174
|
+
const sourceDir = dirname10(sourceFilePath);
|
|
10175
|
+
const transpiledScript = transpiler3.transformSync(strippedScript).replace(/(['"])(\.{1,2}\/[^'"]+)(['"])/g, (_2, quoteStart, relativeImport, quoteEnd) => `${quoteStart}${toJs(relativeImport, sourceDir)}${quoteEnd}`);
|
|
10169
10176
|
const packageImportRewrites = new Map;
|
|
10170
10177
|
for (const [bareImport, absolutePath] of packageComponentPaths) {
|
|
10171
10178
|
const childResult = cacheMap.get(absolutePath);
|
|
@@ -10187,7 +10194,7 @@ var resolveDevClientDir3 = () => {
|
|
|
10187
10194
|
source: descriptor.template?.content ?? "",
|
|
10188
10195
|
ssr,
|
|
10189
10196
|
ssrCssVars: descriptor.cssVars
|
|
10190
|
-
}).code.replace(/(['"])(\.{1,2}\/[^'"]+)(['"])/g, (_2, quoteStart, relativeImport, quoteEnd) => `${quoteStart}${toJs(relativeImport)}${quoteEnd}`);
|
|
10197
|
+
}).code.replace(/(['"])(\.{1,2}\/[^'"]+)(['"])/g, (_2, quoteStart, relativeImport, quoteEnd) => `${quoteStart}${toJs(relativeImport, sourceDir)}${quoteEnd}`);
|
|
10191
10198
|
const localCss = await Promise.all(descriptor.styles.map(async (styleBlock) => compiler.compileStyle({
|
|
10192
10199
|
filename: sourceFilePath,
|
|
10193
10200
|
id: componentId,
|
|
@@ -17899,5 +17906,5 @@ export {
|
|
|
17899
17906
|
build
|
|
17900
17907
|
};
|
|
17901
17908
|
|
|
17902
|
-
//# debugId=
|
|
17909
|
+
//# debugId=3AAA82D7EC0F5B9564756E2164756E21
|
|
17903
17910
|
//# sourceMappingURL=build.js.map
|