- Can I use this bundle directly in a Laravel project without Symfony?
- No, this bundle is designed for Symfony and requires EasyAdmin. For Laravel, you’d need to either wrap it in a Symfony microkernel (e.g., Luminary) or build a custom API layer to expose FAQ data via REST/GraphQL. Alternatively, consider Laravel-specific packages like spatie/laravel-faq.
- What Symfony and PHP versions does the latest version (3.x) support?
- The 3.x branch supports Symfony 6.4 and 7.x with PHP 8.2 or higher. Older branches (2.x, 1.x) cover Symfony 5.4–6.x and 4.4–5.x, respectively, but 1.x is no longer maintained. Always check the branch matrix for exact compatibility.
- How do I add FAQ entries and categories to my EasyAdmin dashboard?
- Extend your `DashboardController` to include `MenuItem` links for `Entry` and `Category` entities. Use `linkToCrud()` for each, and optionally group them under a section with `section()`. Clear the cache afterward to apply changes. Example provided in the README.
- Does this bundle include a frontend template for displaying FAQs?
- No, the bundle only provides the backend CRUD for managing FAQ entries and categories via EasyAdmin. You’ll need to create your own Twig or Blade templates to render FAQs on your frontend, using the Doctrine entities it generates.
- How do I change the root path where FAQs are displayed (e.g., `/support/faq`)?
- Configure the `root_path` in `config/packages/easy_faq.yaml` under the `page` key. After updating, clear your Symfony cache (`php bin/console cache:clear`) because the route loader needs to be refreshed for changes to take effect.
- Will this bundle work with my existing Laravel database schema?
- No, the bundle assumes a Doctrine-based schema. If you’re migrating from Laravel, you’ll need to manually map your existing FAQ tables (e.g., `questions`, `answers`) to the bundle’s `Entry` and `Category` entities, likely via a custom migration or data import script.
- Are there any alternatives for Laravel that offer similar FAQ management?
- Yes, for Laravel, consider `spatie/laravel-faq` (simple CRUD + Blade templates) or `orchid/platform` (if you’re using Orchid). If you’re using Symfony, this bundle is a lightweight option compared to full-fledged CMS plugins like SonataAdmin.
- How do I handle multilingual FAQs with this bundle?
- The bundle doesn’t natively support multilingual content. For translations, you’d need to extend the `Entry` entity with translation fields (e.g., using `gedmo/translatable`) or manage translations separately in your frontend logic.
- What happens if I upgrade Symfony but keep an older version of this bundle?
- Using an older bundle version with a newer Symfony release may cause compatibility issues, such as deprecated API calls or missing features. Always align your bundle version with your Symfony major version (e.g., Symfony 7.x → bundle 3.x).
- Is there a way to test the FAQ functionality before deploying to production?
- Yes, test the CRUD functionality in your EasyAdmin dashboard by creating dummy FAQ entries and categories. For frontend rendering, mock the routes in your tests or use Symfony’s `WebTestCase` to verify Twig/Blade templates display FAQs correctly.