mirror of
https://github.com/HolgerHatGarKeineNode/einundzwanzig-app.git
synced 2026-06-11 02:50:29 +00:00
✨ **Add public API documentation access and navigation links**
- 📚 Added "API Dokumentation" link to the sidebar and header navigation. - 🔓 Defined `viewApiDocs` gate for public access to API documentation. - ✅ Added feature tests for API documentation route accessibility and OpenAPI document serving.
This commit is contained in:
@@ -10,6 +10,7 @@ use Illuminate\Foundation\Events\DiagnosingHealth;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Support\Facades\Date;
|
||||
use Illuminate\Support\Facades\Event;
|
||||
use Illuminate\Support\Facades\Gate;
|
||||
use Illuminate\Support\Facades\RateLimiter;
|
||||
use Illuminate\Support\Facades\Route;
|
||||
use Illuminate\Support\Facades\URL;
|
||||
@@ -37,6 +38,8 @@ class AppServiceProvider extends ServiceProvider
|
||||
{
|
||||
$this->configureRateLimiting();
|
||||
|
||||
Gate::define('viewApiDocs', fn (?Authenticatable $user = null): bool => true);
|
||||
|
||||
if ($this->app->environment('production')) {
|
||||
URL::forceScheme('https');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user