This package contains a set of useful Bootstrap Laravel Blade components. It promotes DRY principles and allows you to keep your BLADE FILES nice and clean.
Install the package via composer:
composer require nfgarching/laravel-bootstrap-componentsThe package will automatically register itself. You can publish the package with:
php artisan vendor:publish --provider="Nfgarching\Componets\LibraryServiceProvider"Installation from https://github.com/nfgarching/laravel-bootstrap-componets
To test out the package installation, you’ll need a new Laravel project. Create a new project somewhere on your computer with the name e.g. example-app.
composer create-project laravel/laravel example-appBy default, Composer pulls in packages from Packagist so you’ll have to make a slight adjustment to your new project composer.json file. Open the file and update include the following array somewhere in the object:
"repositories": [
{
"type": "vcs",
"url": "https://github.com/nfgarching/laravel-bootstrap-componets"
}
]Execute the following command to install the package:
composer require nfgarching/laravel-bootstrap-componentsThe package will automatically register itself. You can publish the package with:
php artisan vendor:publish --provider="Nfgarching\Componets\LibraryServiceProvider"To further develop the package, you’ll need a new Laravel project. Create a new project somewhere on your computer with the name e.g. example-app.
composer create-project laravel/laravel example-appClone the package as follow:
mkdir -p packages/nfgarching
cd packages/nfgarching
git clone git@github.com:nfgarching/laravel-bootstrap-componets.git
composer require livewire/livewireOpen composer.json an add in section
"autoload": {
"psr-4": {
...,
"Nfgarching\\Componets\\": "packages/nfgarching/laravel-bootstrap-componets/src/"
}
},Now, open the bootstrap/provider.php file and add to the providers array following:
return [
App\Providers\AppServiceProvider::class,
Nfgarching\Componets\LibraryServiceProvider::class,
];composer dump-autoload
php artisan vendor:publish --provider="Nfgarching\Componets\LibraryServiceProvider"This will register the PackageServiceProvider class as one of the service providers for this project. Start the application using php artisan serve and visit the /dashboard route to get dashboard.
Soution ist to disable CSRF token for Livewire 1 2 3
Add in bootstrap\app.php
->withMiddleware(function (Middleware $middleware) {
$middleware->validateCsrfTokens(except: [
'livewire/*'
]);
})The MIT License (MIT). Please see License File for more information.