Skip to content

Commit bbe3e7f

Browse files
authored
fix: kebab namespace cannot invert to camel correctly (#521)
1 parent 99100e7 commit bbe3e7f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/core/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ export function getNameFromFilePath(filePath: string, options: ResolvedOptions):
139139
if (globalNamespaces.some((name: string) => folders.includes(name)))
140140
folders = folders.filter(f => !globalNamespaces.includes(f))
141141

142-
folders = folders.map(f => f.replace(/[^a-zA-Z0-9]/g, ''))
142+
folders = folders.map(f => f.replace(/[^a-zA-Z0-9\-]/g, ''))
143143

144144
if (filename.toLowerCase() === 'index')
145145
filename = ''

0 commit comments

Comments
 (0)