silgi 0.23.6 → 0.23.8
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/_chunks/index.mjs +1 -1
- package/dist/kit/index.d.mts +8 -2
- package/dist/kit/index.d.ts +8 -2
- package/dist/kit/index.mjs +8 -5
- package/package.json +1 -1
package/dist/_chunks/index.mjs
CHANGED
package/dist/kit/index.d.mts
CHANGED
|
@@ -156,6 +156,12 @@ declare const MODE_RE: RegExp;
|
|
|
156
156
|
declare function hasSilgiModule(moduleKey: string, silgi?: SilgiCLI): boolean;
|
|
157
157
|
declare function hasInstalledModule(moduleKey: string, silgi?: SilgiCLI): boolean;
|
|
158
158
|
declare const baseHeaderBannerComment: string[];
|
|
159
|
-
|
|
159
|
+
/**
|
|
160
|
+
* Process file paths based on configuration settings
|
|
161
|
+
*
|
|
162
|
+
* @param path - The source file path to process
|
|
163
|
+
* @returns The processed path with extensions and trailing slashes handled
|
|
164
|
+
*/
|
|
165
|
+
declare function processFilePath(path: string): string;
|
|
160
166
|
|
|
161
|
-
export { MODE_RE,
|
|
167
|
+
export { MODE_RE, addTemplate, applyEnv, baseHeaderBannerComment, createResolver, defineSilgiModule, defineSilgiPreset, directoryToURL, filterInPlace, genEnsureSafeVar, getAllEntries, getIpAddress, hasError, hasInstalledModule, hasSilgiModule, hash, initRuntimeConfig, ipAddress, isDirectory, isH3, isNitro, isNuxt, normalizeTemplate, parseServices, prettyPath, processFilePath, relativeWithDot, resolveAlias, resolvePath, resolveSilgiModule, resolveSilgiPath, serviceParseModule, toArray, tryResolveModule, useLogger, useRequest, useResponse, useSilgiRuntimeConfig, writeFile };
|
package/dist/kit/index.d.ts
CHANGED
|
@@ -156,6 +156,12 @@ declare const MODE_RE: RegExp;
|
|
|
156
156
|
declare function hasSilgiModule(moduleKey: string, silgi?: SilgiCLI): boolean;
|
|
157
157
|
declare function hasInstalledModule(moduleKey: string, silgi?: SilgiCLI): boolean;
|
|
158
158
|
declare const baseHeaderBannerComment: string[];
|
|
159
|
-
|
|
159
|
+
/**
|
|
160
|
+
* Process file paths based on configuration settings
|
|
161
|
+
*
|
|
162
|
+
* @param path - The source file path to process
|
|
163
|
+
* @returns The processed path with extensions and trailing slashes handled
|
|
164
|
+
*/
|
|
165
|
+
declare function processFilePath(path: string): string;
|
|
160
166
|
|
|
161
|
-
export { MODE_RE,
|
|
167
|
+
export { MODE_RE, addTemplate, applyEnv, baseHeaderBannerComment, createResolver, defineSilgiModule, defineSilgiPreset, directoryToURL, filterInPlace, genEnsureSafeVar, getAllEntries, getIpAddress, hasError, hasInstalledModule, hasSilgiModule, hash, initRuntimeConfig, ipAddress, isDirectory, isH3, isNitro, isNuxt, normalizeTemplate, parseServices, prettyPath, processFilePath, relativeWithDot, resolveAlias, resolvePath, resolveSilgiModule, resolveSilgiPath, serviceParseModule, toArray, tryResolveModule, useLogger, useRequest, useResponse, useSilgiRuntimeConfig, writeFile };
|
package/dist/kit/index.mjs
CHANGED
|
@@ -488,13 +488,16 @@ const baseHeaderBannerComment = [
|
|
|
488
488
|
"/* prettier-ignore */",
|
|
489
489
|
"/* tslint:disable */"
|
|
490
490
|
];
|
|
491
|
-
function
|
|
491
|
+
function processFilePath(path) {
|
|
492
492
|
const silgi = useSilgiCLI();
|
|
493
|
+
const cleanPath = path.endsWith("/") ? path.slice(0, -1) : path;
|
|
494
|
+
if (cleanPath.endsWith("/.ts")) {
|
|
495
|
+
return cleanPath;
|
|
496
|
+
}
|
|
493
497
|
if (silgi.options.typescript.removeFileExtension) {
|
|
494
|
-
|
|
495
|
-
return src;
|
|
498
|
+
return cleanPath.replace(/\.ts$/, "");
|
|
496
499
|
}
|
|
497
|
-
return
|
|
500
|
+
return cleanPath;
|
|
498
501
|
}
|
|
499
502
|
|
|
500
503
|
function addTemplate(_template) {
|
|
@@ -627,4 +630,4 @@ function isValidIp(ip) {
|
|
|
627
630
|
return false;
|
|
628
631
|
}
|
|
629
632
|
|
|
630
|
-
export { MODE_RE,
|
|
633
|
+
export { MODE_RE, addTemplate, applyEnv, baseHeaderBannerComment, createResolver, defineSilgiModule, defineSilgiPreset, directoryToURL, filterInPlace, genEnsureSafeVar, getAllEntries, getIpAddress, hasError, hasInstalledModule, hasSilgiModule, hash, initRuntimeConfig, ipAddress, isDirectory$1 as isDirectory, isH3, isNitro, isNuxt, normalizeTemplate, parseServices, prettyPath, processFilePath, relativeWithDot, resolveAlias, resolvePath, resolveSilgiModule, resolveSilgiPath, serviceParseModule, toArray, tryResolveModule, useLogger, useRequest, useResponse, useSilgiRuntimeConfig, writeFile };
|