File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -158,7 +158,8 @@ function resolveLaravelPlugin(pluginConfig: Required<PluginConfig>): LaravelPlug
158158 fs . writeFileSync ( hotFile , viteDevServerUrl )
159159
160160 setTimeout ( ( ) => {
161- server . config . logger . info ( colors . red ( `\n ${ colors . bold ( 'Laravel' ) } ${ laravelVersion ( ) } ` ) )
161+ server . config . logger . info ( `\n ${ colors . red ( `${ colors . bold ( 'LARAVEL' ) } ${ laravelVersion ( ) } ` ) } ${ colors . dim ( 'plugin' ) } ${ colors . bold ( `v${ pluginVersion ( ) } ` ) } ` )
162+ server . config . logger . info ( '' )
162163 server . config . logger . info ( ` ${ colors . green ( '➜' ) } ${ colors . bold ( 'APP_URL' ) } : ${ colors . cyan ( appUrl . replace ( / : ( \d + ) / , ( _ , port ) => `:${ colors . bold ( port ) } ` ) ) } ` )
163164 } , 100 )
164165 }
@@ -215,6 +216,17 @@ function laravelVersion(): string {
215216 }
216217}
217218
219+ /**
220+ * The version of the Laravel Vite plugin being run.
221+ */
222+ function pluginVersion ( ) : string {
223+ try {
224+ return JSON . parse ( fs . readFileSync ( path . join ( __dirname , '../package.json' ) ) . toString ( ) ) ?. version
225+ } catch {
226+ return ''
227+ }
228+ }
229+
218230/**
219231 * Convert the users configuration into a standard structure with defaults.
220232 */
You can’t perform that action at this time.
0 commit comments