Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TypeDeclaration] Add TypedPropertyFromJMSSerializerAttributeTypeRector #5909

Merged
merged 9 commits into from
May 24, 2024

Conversation

samsonasik
Copy link
Member

@samsonasik
Copy link
Member Author

All checks have passed 🎉 @TomasVotruba I think it is ready.

#[\JMS\Serializer\Annotation\Type('string')]
private $name;

public function setName(string $name): void
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

assign typed already covered by other rule

https://getrector.com/demo/96ca5ad6-dd87-406e-88bf-6e073ed17e32

final class SkipWithDefault
{
#[\JMS\Serializer\Annotation\Type('string')]
private $name = 'foo';
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With default already covered by other rule https://getrector.com/demo/2479ea75-5faa-45b5-8b62-7738cc69d1ec

@TomasVotruba
Copy link
Member

Looks great 👍 Thanks for skipping the cases covered by other rules, so we have indepedent rules

@TomasVotruba TomasVotruba merged commit d6fc901 into main May 24, 2024
42 checks passed
@TomasVotruba TomasVotruba deleted the jms-type branch May 24, 2024 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[TypeDeclaration] Add typed property based on serialize attribute
2 participants