ibobdb/laravel-stisla
Composer 安装命令:
composer require ibobdb/laravel-stisla
包简介
README 文档
README
LaravelStisla is an authentication starter,powered by Laravel Fortify.This packages can be used to start your project shorter,it include all feature that laravel recommended implementing yourself.
Instalation
To get started, you will need to install LaravelStisla using composer.This will install Laravel Fortify as well so.
composer require ibobdb/laravel-stisla
Next,run the install command:
php artisan LaravelStisla:install
This command will publish LaravelStisla providers,views and assets directory.
Install Stisla depencies. Go to stisla directory Public/stisla.
yarn install
It will install all assets depedencies
Configuration
Add this to your FortifyServiceProvider.php in the boot() method.
Fortify::loginView(function () { return view('auth.login'); }); Fortify::registerView(function () { return view('auth.register'); }); Fortify::requestPasswordResetLinkView(function () { return view('auth.forgot-password'); }); Fortify::resetPasswordView(function ($request) { return view('auth.reset-password', ['request' => $request]); }); // Fortify::verifyEmailView(function () { // return view('auth.verify-email'); // }); // Fortify::confirmPasswordView(function () { // return view('auth.confirm-password'); // }); // Fortify::twoFactorChallengeView(function () { // return view('auth.two-factor-challenge'); // });
In the file RouteServiceProvider.php
public const HOME = '/home' //change to public const HOME = '/dashboard'
Add Routes routes/web.php
Route::middleware(['auth:sanctum', 'verified'])->group(function () { Route::get('/dashboard', function () { return view('pages.dashboard'); }); });
This allows you to attach the verified middleware to any of your routes
Features
By default, LaravelStisla is setup to handle the basic authentication functions (Login, Register, Password Reset) provided by Laravel Fortify.
Email Verification
To get started, ensure the emailVerification feature is enabled in your fortify configuration file's features array. Next, you should ensure that your App\Models\User class implements the Illuminate\Contracts\Auth\MustVerifyEmail interface.
use Illuminate\Contracts\Auth\MustVerifyEmail; class User extends Authenticatable implements MustVerifyEmail { ...
Stisla
Check full documentation stisla
Follow
This allows you to attach the verified middleware to any of your routes
License
ibobdb/laravel-stisla 适用场景与选型建议
ibobdb/laravel-stisla 是一款 基于 CSS 开发的 Composer 扩展包,目前已累计 37 次下载、GitHub Stars 达 1, 最近一次更新时间为 2022 年 01 月 04 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 ibobdb/laravel-stisla 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 ibobdb/laravel-stisla 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 37
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-01-04