laravel-crud-generator icon indicating copy to clipboard operation
laravel-crud-generator copied to clipboard

bootstrap laravel ui

Open Haris-Technical-Solutions opened this issue 5 months ago • 3 comments

plz add true false check in config for

because we some time we ahve custome code in loginController and homeController laravel/ui --auth is regenerating the files and removing old code

$this->buildLayout();

protected function buildLayout(): void { if (! (view()->exists($this->layout))) {

        $this->info('Creating Layout ...');

        $uiPackage = match ($this->options['stack']) {
            'tailwind', 'livewire', 'react', 'vue' => 'laravel/breeze',
            default => 'laravel/ui'
        };

        if (! $this->requireComposerPackages([$uiPackage], true)) {
            throw new Exception("Unable to install $uiPackage. Please install it manually");
        }

        $uiCommand = match ($this->options['stack']) {
            'tailwind' => 'php artisan breeze:install blade',
            'livewire' => 'php artisan breeze:install livewire',
            'react' => 'php artisan breeze:install react',
            'vue' => 'php artisan breeze:install vue',
            default => 'php artisan ui bootstrap --auth'
        };

        $this->runCommands([$uiCommand]);
    }
}