symfony/symfony — pull request #8019 by Burgov (2013-05-13 08:24:26+00:00)
Title: [Form] allow binding JSON requests

| Q | A
| ------------- | ---
| Bug fix? | no
| New feature? | yes
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | -
| License | MIT
| Doc PR | -

Since we made a move to Angular for our frontend experience, we are forced to throw data around in JSON format more and more. This PR solves a problem we were forced to solve in our controllers in many occasions.

Also, since JMS serializer bundle by default converts camel case properties to underscore case keys, the reverse had to be supplied at some point. I chose to do this in the PHP side of things.

This all allows me to use the Form component without actually using the FormView (in fact, I'd even vote for splitting the Form and FormView into two components at some point)

This PR of course opens the door for other formats, like XML.