[API] add docs to show API Platform implementation.#147
[API] add docs to show API Platform implementation.#147jrushlow wants to merge 6 commits intoSymfonyCasts:mainfrom
Conversation
|
TODO - Do not return a |
|
Routes: Responses: Responses: |
README.md
Outdated
| * @Assert\NotBlank(groups={"putValidation"}) | ||
| * @Groups({"reset-password:put"}) | ||
| */ | ||
| public string $plainTextPassword; |
There was a problem hiding this comment.
It might be easier to split this into 2 DTO objects - something like RequestResetPasswordInput and ResetPasswordInput. Then you can configure the input on each, specific operation i think (instead of having the input= on the top-level.
Another option would be to create these 2 DTO's and make THEM each their own @ApiResource... each with 1 operation. I'm not sure if having ResetPasswordRequest as the @ApiResource is doing us any favors, as we never use it as the input or output. That would be my biggest potential feedback on this otherwise awesome effort. input and output DTO's are kind of an edge-case feature in API Platform... so if we can find a clean way to do this without them, that might ideal.
|
I assume this is no longer a WIP and is now abandoned? so no api_platform v4.1? Would have bene very useful. |
|
Correct: happy for someone to contribute to it, but @jrushlow is no longer available |
|
I'll see if I have time to make a PR now that I have it working. Might take me a bit though to separate it from my other work. |
This guide is incomplete and should not be used until after it is merged. Everything subject to change until then.
refs #128
Relates to symfony/maker-bundle#798