PHP code example of jeffersongoncalves / filament-security-headers
1. Go to this page and download the library: Download jeffersongoncalves/filament-security-headers 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/ */
jeffersongoncalves / filament-security-headers example snippets
use JeffersonGoncalves\Filament\SecurityHeaders\SecurityHeadersPlugin;
public function panel(Panel $panel): Panel
{
return $panel
->plugins([
SecurityHeadersPlugin::make()
// optional: one of your panel's own groups (string or closure)
->navigationGroup(fn (): string => __('admin.navigation.settings')),
]);
}
bash
composer vendor:publish --tag=filament-security-headers-settings-migrations
php artisan migrate