@stonyx/utils 0.2.3-beta.22 → 0.2.3-beta.24
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/file.js +2 -2
- package/package.json +1 -1
package/dist/file.js
CHANGED
|
@@ -111,10 +111,10 @@ export async function forEachFileImport(dir, callback, options = {}) {
|
|
|
111
111
|
await forEachFileImport(filePath, callback, newOptions);
|
|
112
112
|
continue;
|
|
113
113
|
}
|
|
114
|
-
if (!stats.isFile() || !file.endsWith('.js'))
|
|
114
|
+
if (!stats.isFile() || !(file.endsWith('.js') || file.endsWith('.ts')))
|
|
115
115
|
continue;
|
|
116
116
|
const prefix = process.platform === 'win32' ? 'file://' : '';
|
|
117
|
-
const rawName = file.replace(
|
|
117
|
+
const rawName = file.replace(/\.(js|ts)$/, '');
|
|
118
118
|
let name = options.rawName ? rawName : kebabCaseToCamelCase(rawName);
|
|
119
119
|
if (options.namePrefix)
|
|
120
120
|
name = `${options.namePrefix}${name}`;
|