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

Add option to exclude or select props with the new Equatable macro #195

Open
MiniSuperDev opened this issue Dec 26, 2024 · 2 comments
Open
Assignees
Labels
question Further information is requested waiting for response Waiting for follow up

Comments

@MiniSuperDev
Copy link

MiniSuperDev commented Dec 26, 2024

Hi, there might be cases where you want to customize the behavior a bit more and it would be useful to be able to decide which props to use.

From what I see EquatableMixin will be removed, so there is no way to do it currently in version 3.0.

Thanks

By the way, there are packages that depend on Equatable and without the Mixin, in case you don't use all the props but only a few like my case now, you will be forced to do it manually when version 3.0 comes out.
There, couldn't the mixin also be preserved apart from the new macro?

@MiniSuperDev MiniSuperDev changed the title Add option to exclude or select props with the new Add option to exclude or select props with the new Equatable macro Dec 26, 2024
@felangel
Copy link
Owner

felangel commented Jan 2, 2025

Hi @MiniSuperDev 👋
Thanks for opening an issue!

Can you please provide some context/use cases to illustrate why you only want to include certain properties in the value comparison? That seems like a misuse of package:equatable and you'd be better off writing your own operator== override.

@felangel felangel added question Further information is requested waiting for response Waiting for follow up labels Jan 2, 2025
@felangel felangel self-assigned this Jan 2, 2025
@felangel
Copy link
Owner

I'm happy to keep the EquatableMixin around in the v3.0.0 release since it'll make it easier for folks to migrate incrementally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested waiting for response Waiting for follow up
Projects
None yet
Development

No branches or pull requests

2 participants