FOSRestBundle
FOSRestBundle copied to clipboard
Update version match documentation
Matching version argument does not work, as it's null. Use requirements instead.
Also see https://github.com/symfony/symfony/issues/38034
I think we should have both examples. If the version is not derived from the path, you will still need to use the condition option. You can take a look at the Version2Controller class in the tests which contains examples for both.
Hmm, but won't that require a more structural update? How will that work with multiple options enabled, for instance? https://symfony.com/doc/3.x/bundles/FOSRestBundle/versioning.html#how-to-version-your-api