@@ -137,9 +137,9 @@ async function writeTypes(distDir: string, meta: ModuleMeta) {
137137 )
138138 const isStub = moduleTypes . includes ( 'export *' )
139139
140- const appShims = [ ]
141- const schemaShims = [ ]
142- const moduleImports = [ ]
140+ const appShims : string [ ] = [ ]
141+ const schemaShims : string [ ] = [ ]
142+ const moduleImports : string [ ] = [ ]
143143
144144 const hasTypeExport = ( name : string ) => isStub || typeExports . find ( exp => exp . names . includes ( name ) )
145145
@@ -154,7 +154,7 @@ async function writeTypes(distDir: string, meta: ModuleMeta) {
154154 }
155155
156156 if ( hasTypeExport ( 'ModuleRuntimeHooks' ) ) {
157- const runtimeHooksInterfaces = [ ]
157+ const runtimeHooksInterfaces : string [ ] = [ ]
158158
159159 if ( hasTypeExport ( 'ModuleRuntimeHooks' ) ) {
160160 runtimeHooksInterfaces . push ( 'ModuleRuntimeHooks' )
@@ -184,7 +184,7 @@ ${typeExports[0] ? `\nexport type { ${typeExports[0].names.join(', ')} } from '.
184184
185185 await fsp . writeFile ( dtsFile , dtsContents , 'utf8' )
186186 if ( ! existsSync ( dtsFileMts ) ) {
187- await fsp . writeFile ( dtsFileMts , dtsContents . replaceAll ( '. /module' , './module.js' ) , 'utf8' )
187+ await fsp . writeFile ( dtsFileMts , dtsContents . replace ( / \. \ /m o d u l e / g , './module.js' ) , 'utf8' )
188188 }
189189}
190190
0 commit comments