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

Refactored module, use graphql #5

Merged
merged 5 commits into from
Apr 9, 2024
Merged

Conversation

BobWez98
Copy link
Collaborator

@BobWez98 BobWez98 commented Apr 8, 2024

No description provided.

return;
}

let response = await magentoGraphQL("query($uid: ID!) { compareList(uid: $uid) { uid item_count attributes { code label } items { uid product { sku name url_key image { url label } } attributes { code value } } } }", {
Copy link
Member

Choose a reason for hiding this comment

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

So we don't acidentally mismatch the data i think we should extract the compareList data into it's own variable like we have done for the cart in the core
https://github.com/rapidez/core/blob/a8a399077136af19acb4edda4fdae2a8171f125e/resources/js/stores/useCart.js#L23
https://github.com/rapidez/core/blob/a8a399077136af19acb4edda4fdae2a8171f125e/src/Http/ViewComposers/ConfigComposer.php#L45

}

export const clear = async function () {
compare.value = {}
Copy link
Member

Choose a reason for hiding this comment

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

@BobWez98 BobWez98 requested a review from indykoning April 9, 2024 06:14
@indykoning indykoning changed the title Refactored the whole module Refactored module, use graphql Apr 9, 2024
@indykoning indykoning merged commit a7e17e5 into rapidez:master Apr 9, 2024
1 check failed
@@ -0,0 +1,3 @@
<?php

Route::view(config('rapidez.compare.route'), 'rapidez-compare::compare')->name('rapidez-compare::compare');
Copy link
Member

Choose a reason for hiding this comment

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

Is prefixing the route name like views a common thing?

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.

4 participants