Download the PHP package vigihdev/symfony-bridge-config without Composer
On this page you can find all versions of the php package vigihdev/symfony-bridge-config. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package symfony-bridge-config
Symfony Bridge Config
A lightweight configuration bridge for Symfony components that provides easy environment and YAML configuration management with dependency injection container support.
Installation
Quick Start
Simple Usage with Boot Method
Manual Configuration
Features
- Environment Loading: Automatic
.envfile loading withputenv()support - YAML Configuration: Load multiple YAML configuration files
- Custom Configurations: Add Symfony Configuration classes
- Service Locator: Static access to container services and parameters
- Dependency Injection: Full Symfony DI container support
Configuration Structure
Environment Variables
Create a .env file in your project root:
YAML Configuration
Create config/services.yaml:
Custom Configuration Classes
API Reference
ConfigBridge
Static Methods
ConfigBridge::boot(string $basePath, string $configDir = 'config'): static- Bootstrap with automatic configuration loading
Instance Methods
__construct(string $basePath)loadEnv(?string $path = null): voidloadConfig(string $configDir): voidaddConfiguration(ConfigurationInterface $config, ?string $id = null): voidcompile(): ContainerBuilderget(string $id): ?objecthas(string $id): boolcontainer(): ContainerBuilder
ServiceLocator
Static Methods
ServiceLocator::setContainer(ContainerInterface $container): voidServiceLocator::getContainer(): ContainerInterfaceServiceLocator::get(string $id): objectServiceLocator::getParameter(string $name): mixedServiceLocator::hasParameter(string $name): boolServiceLocator::has(string $id): bool
Testing
Run the test suite:
Test coverage includes:
- Environment variable loading
- YAML configuration parsing
- Service container management
- Configuration object registration
- ServiceLocator functionality
- Integration testing
Requirements
- PHP 8.1+
- Symfony Config Component
- Symfony DependencyInjection Component
- Symfony Dotenv Component
License
This project is licensed under the MIT License.
All versions of symfony-bridge-config with dependencies
PHP Build Version
Package Version
Requires
php Version
^8.1
symfony/config Version ^6.4
symfony/dependency-injection Version ^6.4
symfony/yaml Version ^6.4
symfony/dotenv Version ^6.4
symfony/filesystem Version ^6.4
symfony/config Version ^6.4
symfony/dependency-injection Version ^6.4
symfony/yaml Version ^6.4
symfony/dotenv Version ^6.4
symfony/filesystem Version ^6.4
The package vigihdev/symfony-bridge-config contains the following files
Loading the files please wait ...