@@ -128,6 +128,16 @@ export class ModuleWindowsSetup {
128128 return this . getModuleName ( packageName ) ;
129129 }
130130
131+ public async getFinalModuleName ( ) : Promise < string > {
132+ try {
133+ const packageJsonPath = path . join ( this . root , 'package.json' ) ;
134+ const pkgJson = JSON . parse ( await fs . readFile ( packageJsonPath , 'utf8' ) ) ;
135+ return this . getActualModuleName ( pkgJson . name || 'SampleModule' ) ;
136+ } catch {
137+ return 'SampleModule' ;
138+ }
139+ }
140+
131141 private verboseMessage ( message : any ) {
132142 if ( this . options . logging ) {
133143 console . log ( `[ModuleWindowsSetup] ${ message } ` ) ;
@@ -1281,6 +1291,9 @@ export async function moduleWindowsSetupInternal(
12811291 await setup . run ( spinner , config ) ;
12821292 const endTime = performance . now ( ) ;
12831293
1294+ // Get the actual module name for display
1295+ const moduleName = await setup . getFinalModuleName ( ) ;
1296+
12841297 console . log (
12851298 `${ chalk . green ( 'Success:' ) } Windows module setup completed! (${ Math . round (
12861299 endTime - startTime ,
@@ -1294,13 +1307,13 @@ export async function moduleWindowsSetupInternal(
12941307 console . log ( chalk . bold ( 'Files created/updated:' ) ) ;
12951308 console . log ( `📄 package.json - Added codegen configuration` ) ;
12961309 console . log (
1297- `🏗️ NativeModuleName .ts - TurboModule spec file (edit with your API)` ,
1310+ `🏗️ Native ${ moduleName } .ts - TurboModule spec file (edit with your API)` ,
12981311 ) ;
12991312 console . log (
1300- `💻 windows/ModuleName .h - C++ header file (implement your methods here)` ,
1313+ `💻 windows/${ moduleName } .h - C++ header file (implement your methods here)` ,
13011314 ) ;
13021315 console . log (
1303- `⚙️ windows/ModuleName .cpp - C++ implementation file (add your logic here)` ,
1316+ `⚙️ windows/${ moduleName } .cpp - C++ implementation file (add your logic here)` ,
13041317 ) ;
13051318 console . log ( '' ) ;
13061319 console . log ( chalk . bold ( 'Next steps:' ) ) ;
0 commit comments