1. Go to this page and download the library: Download fayne/laravel-filament-page library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
fayne / laravel-filament-page example snippets
use Fayne\Page\Filament\PagePlugin;
return $panel->plugins([
// Keep the host's existing plugins.
PagePlugin::make(),
]);
namespace App\Models;
class Page extends \Fayne\Page\Models\Page
{
}
namespace App\Filament\Resources;
use Fayne\Page\Filament\Resources\PageResource as BasePageResource;
use Filament\Forms\Components\TextInput;
use Filament\Schemas\Schema;
class PageResource extends BasePageResource
{
public static function form(Schema $schema): Schema
{
$schema = parent::form($schema);
return $schema->components([
...$schema->getComponents(),
TextInput::make('extra_data.project_note'),
]);
}
}