Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Sulu Site Configuration Bundle

Sulu Site Configuration Bundle Laravel Package

agence-raid/sulu-site-configuration-bundle

View on GitHub
Deep Wiki
Context7

At a glance

Frequently asked questions about Sulu Site Configuration Bundle
Can I use this bundle in a standalone Laravel project without Sulu CMS?
No, this bundle is tightly coupled with Sulu CMS (v3.0+) and requires its core services (e.g., WebspaceResolver, MediaService). You’d need to abstract or rewrite these dependencies to work with Laravel’s ecosystem, which isn’t officially supported.
What Laravel versions does this bundle support?
The bundle is designed for Sulu CMS, which primarily supports PHP 8.1+ and Symfony 6.x. Laravel compatibility isn’t guaranteed, as it relies on Symfony’s ORM and dependency injection, not Laravel’s Eloquent or Service Container.
How do I migrate existing Laravel config data into this bundle?
You’ll need to manually export your current config data (e.g., from Laravel’s `config()` or a database table) and import it into the bundle’s Doctrine JSON entities. Use the `SiteConfigurationService` to fetch and update values programmatically.
Does this bundle work with Laravel’s Blade templates?
No, it provides Twig helpers (`site_config()`) and assumes Sulu’s Twig integration. For Blade, you’d need to create a custom facade or service that wraps the `SiteConfigurationService` to expose the same data in Laravel’s templating system.
How do I customize the form fields for my webspace?
Create an XML form file at `config/forms/webspace_configs/{webspace-key}.xml` with a `<key>` matching your webspace (e.g., `site_configuration_mywebspace`). The bundle supports field types like `text_line`, `single_media_selection`, and more, documented in Sulu’s form schema.
Will this bundle conflict with Laravel’s migrations?
Yes, the bundle uses Doctrine migrations, which may conflict with Laravel’s Eloquent migrations. Run `bin/adminconsole doctrine:migrations:diff` and `migrate` separately, or manually merge migration files to avoid schema conflicts.
How do I handle media uploads (e.g., logos) in Laravel instead of Sulu’s media system?
The `single_media_selection` field type depends on Sulu’s media system. To replace it, you’d need to create a custom field type or use a Laravel-compatible media library like Spatie Media Library, then extend the `SiteConfigurationService` to work with your chosen storage.
Can I use this bundle with Laravel Nova or Filament for admin management?
No, the bundle integrates with Sulu’s admin UI. To use Laravel Nova or Filament, you’d need to rebuild the configuration management interface from scratch, leveraging the `SiteConfigurationService` to fetch and update data via your preferred admin panel.
What are the performance implications of storing configs as JSON in Doctrine?
JSON storage in Doctrine can bloat queries if not indexed properly. For Laravel, consider caching frequently accessed configs (e.g., using Laravel’s cache system) or optimizing Doctrine queries with custom repository methods.
Are there alternatives for multi-webspace/multi-locale configs in Laravel?
Yes, for Laravel, consider packages like Stancl/Tenancy for multi-tenancy, Spatie’s Laravel Translatable for locales, or custom solutions using Laravel’s `config()` with dynamic keys (e.g., `config('webspaces.mywebspace.locales.fr.email')`). These avoid Sulu’s dependencies entirely.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
nasirkhan/laravel-sharekit
directorytree/privacy-filter-classifier
directorytree/privacy-filter
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin
splash/metadata
splash/openapi
splash/scopes
splash/toolkit
testo/output-teamcity
testo/bridge-symfony