- Does this package replace Laravel’s default routing system, or does it work alongside it?
- This package extends Laravel’s routing rather than replacing it. It integrates with `routes/web.php` and allows you to define CMS-powered routes while preserving existing Laravel route logic. Conflicts are avoided via middleware priority and explicit route grouping. For migrations, you’ll map old routes to the package’s abstractions incrementally.
- What Laravel versions does `capell-app/frontend` support, and is it compatible with Laravel 10.x?
- The package was last updated in 2026, but its Laravel ecosystem compatibility suggests support for Laravel 10.x and likely 11.x. Always verify the `laravel/framework` constraint in `composer.json` and test with your specific version. If using Laravel 11, check for breaking changes in Blade or routing.
- How does caching work for dynamic content like themes or route-specific data?
- The package leverages Laravel’s cache drivers (Redis/Memcached recommended) with explicit boundaries—routes, themes, and content are cached independently. Cache keys are generated per route or theme, and invalidation can be triggered via Laravel’s cache tags or queue listeners. For distributed setups, Redis is ideal for tag-based invalidation.
- Can I use this package with Inertia.js or Livewire for SPA/hybrid frontends?
- Yes, but with adaptations. The package primarily targets Blade rendering, so for Inertia.js/Livewire, you’ll need to wrap its routes in proxies or use custom Blade components to bridge dynamic CMS content. The package doesn’t enforce a frontend paradigm, but SPA routes may require additional middleware to handle theme/context data.
- What happens if a theme is missing or fails to load? Does it have fallback mechanisms?
- The package includes fallback logic for missing themes, typically defaulting to a `null` or `default` theme. Theme load failures trigger a `ThemeNotFoundException`, which you can catch in a global exception handler to serve a fallback view or redirect. Error handling is customizable via service provider configuration.
- How do I integrate this with Capell CMS’s Eloquent models or API endpoints?
- The package assumes Capell CMS provides Eloquent models or API endpoints for content/themes. You’ll need to bind these dependencies in the service provider (e.g., `ThemeRepository`, `ContentFetcher`). Undocumented dependencies can cause issues, so audit `composer.json` and test with a sandbox Capell instance to identify required services.
- Does this package support composable themes (e.g., parent/child themes like WordPress)?
- Yes, the package supports theme inheritance and composition. Themes can extend or override parent themes via Laravel’s view merging logic. Configuration files (e.g., `config/capell-themes.php`) define theme hierarchies, and Blade directives handle dynamic includes. Fallback chains ensure missing components don’t break rendering.
- What’s the performance impact of using this package for high-traffic routes?
- The package is optimized for performance with granular caching boundaries. Benchmark your routes with/without it to identify bottlenecks, especially if using complex theme logic or dynamic content. Redis is recommended for distributed caching, and queue-based invalidation minimizes redundant computations during theme/content updates.
- Are there alternatives to this package for Laravel CMS frontend abstraction?
- Alternatives include `spatie/laravel-cms` for modular CMS frontends, `orchid/software` for admin/CMS hybrids, or custom solutions using Laravel’s service containers and Blade components. This package is Capell-specific, offering tighter integration with its CMS layer but may lack the flexibility of general-purpose tools.
- How do I test this package in a staging environment before production deployment?
- Start by forking the package and testing it in isolation with a Capell CMS sandbox. Use Laravel’s `php artisan route:list` to verify route conflicts, and simulate high traffic with tools like Artisan commands or HTTP load testers. Monitor cache behavior and theme rendering edge cases before incremental rollout to production.