codebar-ag / laravel-default-nova
Boilerplate integration for Laravel Nova Projects at codebar Solutions AG.
Installs: 13 237
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 1
Forks: 0
Open Issues: 1
Requires
- php: ^8.1
- guzzlehttp/guzzle: ^7.8
- illuminate/contracts: ^10.0
- laravel/nova: ^4.32
- spatie/laravel-package-tools: ^1.16
- spatie/laravel-ray: ^1.33
Requires (Dev)
- laravel/pint: ^1.13
- nunomaduro/collision: ^7.10
- nunomaduro/larastan: ^2.8
- orchestra/testbench: ^8.20
- pestphp/pest: ^2.30
- pestphp/pest-plugin-arch: ^2.6
- pestphp/pest-plugin-laravel: ^2.2
- phpstan/extension-installer: ^1.3
- phpstan/phpstan-deprecation-rules: ^1.1
- phpstan/phpstan-phpunit: ^1.3
- phpunit/phpunit: ^10.5
README
laravel-default-nova
Installation
You can install the package via composer:
composer require codebar-ag/laravel-default-nova
NovaServiceProvider
<?php namespace App\Providers; use CodebarAg\LaravelDefaultNova\Providers\CustomNovaServiceProvider; use Illuminate\Support\Facades\Auth; use Illuminate\Support\Facades\Gate; use Laravel\Nova\Nova; class NovaServiceProvider extends CustomNovaServiceProvider { /** * Bootstrap any application services. * * @return void */ public function boot() { parent::boot(); } /** * Register the Nova routes. * * @return void */ protected function routes() { Nova::routes(); } /** * Register the Nova gate. * * This gate determines who can access Nova in non-local environments. * * @return void */ protected function gate() { Gate::define('viewNova', function ($user) { return Auth::check(); }); } /** * Get the dashboards that should be listed in the Nova sidebar. * * @return array */ protected function dashboards() { return [ new \App\Nova\Dashboards\Main, ]; } /** * Get the tools that should be listed in the Nova sidebar. * * @return array */ public function tools() { return []; } /** * Register any application services. * * @return void */ public function register() { parent::register(); } }
Config
<?php return [ 'prevent_lazy_loading' => app()->isLocal(), 'with_breadcrumbs' => true, 'without_notifications' => false, 'resource_in' => 'Nova/Models', //'initial_path' => '/resources/users', //'assets' => ['js/nova.js', 'css/nova.css'], 'policies' => [ 'namespace' => 'App\\Policies\\Nova\\', ], ];
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.