Skip to content

Commit

Permalink
Remove tsx from replaceDtsWithJsExtensions
Browse files Browse the repository at this point in the history
  • Loading branch information
aryaemami59 committed Oct 15, 2024
1 parent ce5c4bc commit cfd14d3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -255,11 +255,10 @@ export function writeFileSync(filePath: string, content: string) {
*/
export function replaceDtsWithJsExtensions(dtsFilePath: string) {
return dtsFilePath.replace(
/\.d\.(ts|mts|cts|tsx)$/,
/\.d\.(ts|mts|cts)$/,
(_, fileExtension: string) => {
switch (fileExtension) {
case 'ts':
case 'tsx':
return '.js'
case 'mts':
return '.mjs'
Expand Down

0 comments on commit cfd14d3

Please sign in to comment.