Skip to content

Conversation

sunesimonsen
Copy link
Member

@sunesimonsen sunesimonsen commented Jul 30, 2025

In the previous version of array-changes we didn't manage to correctly show structural similar moves, we would just show the actual item being moved.

I opted for just showing a remove and an insert instead of showing a structural diff that is then moved. That simplifies things a bit, but we can always change our minds on this decision.

The plugin failures seems reasonable.

@sunesimonsen sunesimonsen force-pushed the ssimonsen/upgrade-array-changes branch from cd4b9fc to 5bf0333 Compare July 30, 2025 09:56
@sunesimonsen sunesimonsen marked this pull request as ready for review July 30, 2025 11:25
@sunesimonsen sunesimonsen requested a review from papandreou July 30, 2025 11:25
@@ -0,0 +1,25 @@
const arrayChanges = require('array-changes');

module.exports = function (...args) {
Copy link
Member

Choose a reason for hiding this comment

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

If we now need to wrap array-changes I guess we could consider making these adjustments directly in the library, or maybe even just copy the whole thing in here. I don't see this as a blocker, just an observation.

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't think we should do that, because I think we should consider showing the similar diff with a move. I just don't want to make that change right now.

Copy link
Member Author

Choose a reason for hiding this comment

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

Mhh maybe you are right, maybe we don't want to see moves for similar items. Could we merge this, then I'll add an issue to upstream the change into array-changes itself.

Copy link
Member

Choose a reason for hiding this comment

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

Yeah, absolutely!

@sunesimonsen sunesimonsen force-pushed the ssimonsen/upgrade-array-changes branch from 5bf0333 to 57c21c0 Compare July 31, 2025 09:27
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.

2 participants