Download the PHP package gheb/api-platform-config-converter-bundle without Composer
On this page you can find all versions of the php package gheb/api-platform-config-converter-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download gheb/api-platform-config-converter-bundle
More information about gheb/api-platform-config-converter-bundle
Files in gheb/api-platform-config-converter-bundle
Package api-platform-config-converter-bundle
Short Description Convert your API Platform configuration from a format to another
License MIT
Informations about the package api-platform-config-converter-bundle
Configuration Converter
Do not worry about your configuration at first.
When you start working on your project, the documentation (because it's easy to make a POC with) shows you how to configure your resources with annotations. And it's usually a good practice to use annotations.
But when your project is growing, you start to realize that you need to change for a more suitable, maintainable format like XML or YAML. It's time consuming, not painless, and not error free.
This bundle is meant for this occasion.
WARNING: As the API-Platform and Serializer component evolves, there might be uncovered options. Always double check the output for missing pieces, and if you find ones, please help us filling the gaps.
Installation
Register the bundle.
For symfony < 3.4
For symfony > 4
Configuration
Configure the bundle, here are the default values:
Usage
By default we recommend the 'XML' configuration format.
To convert every single one of your entities configuration in xml.
To convert a specific entity configuration in xml.
To use another format, use --format|-f
option.
By default, you'll need to copy and paste the configuration from the CLI output, but you can export the format to a specific directory.
For API-Platform, use --api-platform-output|-apo
option. By default it will export to config/packages/api-platform
directory.
For the serialization groups, use --serializer-groups-output|-sgo
option. By default it will export to config/packages/serialization
directory.
By default, the bundle will try to convert the API-Platform and the attributes groups.
If you only want to convert one or the other, use the --configurations|-c
option.
Contributing
Fork the project, create a branch according to your contribution, code and follow the contributing.md.
Here is the way I see the next versions, any help is welcome :)
- [x] Add YAML support
- [x] Add serialization groups conversion
- [ ] Add assertion conversion
- [ ] Add doctrine conversion
All versions of api-platform-config-converter-bundle with dependencies
symfony/http-foundation Version ^4.3
symfony/serializer Version ^4.3
symfony/config Version ^4.3
symfony/dependency-injection Version ^4.3
symfony/http-kernel Version ^4.3
symfony/console Version ^4.3
symfony/yaml Version ^4.3
symfony/event-dispatcher Version ^4.3
doctrine/annotations Version ^1.6