Closed jasonbouffard closed 13 years ago
The best practice for shared bundles is to use XML for their internal config files. The main reason is that XML config files are validated using the XSD to ensure they are correct.
Thus, for service definition, I personnaly tend to find it more readable when using advanced DIC features: behavior for invalid arguments (YAML only supports 2 of the 3 possible ones btw), complex definitions (using scope, factory services, definition inheritance...). For some of these, YAML uses some conventions like adding a =
or a ?
in the argument reference, whereas XML uses an attribute which is clearer when looking at the file.
Just wondering why you guys seem to favor xml when writing config files for some of these bundles? All of which I appreciate, thank you.