statview/filament-passkeys
最新稳定版本:0.1.12
Composer 安装命令:
composer require statview/filament-passkeys
包简介
README 文档
README
Installation
Install the package
composer require statview/filament-passkeys
Run the migrations
php artisan migrate
Run the assets command of Filament
php artisan filament:assets
Add the HasPasskeys trait to the user mode
<?php use Statview\Passkeys\Concerns\HasPasskeys; class User extends Model { use HasPasskeys; ...
Exclude the passkeys routes from the CSRF check
<?php class VerifyCsrfToken extends Middleware { /** * The URIs that should be excluded from CSRF verification. * * @var array<int, string> */ protected $except = [ 'passkeys/*', ]; }
Add our plugin to your Filament context(s)
<?php use Statview\Passkeys\PasskeysPlugin; class AdminPanel extends PanelProvider { public function panel(Panel $panel): Panel { return $panel // ... ->plugin(PasskeysPlugin::make()) // ... } }
Credits
Inspired and created by following the following article: https://blog.joe.codes/implementing-passkey-authentication-in-your-laravel-app
统计信息
- 总下载量: 579
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 7
- 点击次数: 3
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-09-27