compileHandle('vite'); } /** * Create the command array to create a Process object with */ protected function createCommand(string $configPath): array { $basePath = base_path(); $command = $this->argument('viteArgs') ?? []; array_unshift( $command, $basePath . sprintf('%1$snode_modules%1$s.bin%1$svite', DIRECTORY_SEPARATOR), 'build', $this->option('silent') ? '--logLevel=silent' : '', ); return $command; } /** * Return values to append to the command env */ protected function createCommandEnv(string $configPath): array { return [ 'VITE_BASE' => Str::after($this->getPackagePath($configPath), base_path()), ]; } }