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

Refactor how current cart id and current user token are obtained #2513

Closed
pkarw opened this issue Feb 27, 2019 · 0 comments
Closed

Refactor how current cart id and current user token are obtained #2513

pkarw opened this issue Feb 27, 2019 · 0 comments
Assignees
Labels
P2: Important Priority mark - still high ;) refactor Code refactoring

Comments

@pkarw
Copy link
Collaborator

pkarw commented Feb 27, 2019

What is the motivation for adding / enhancing this feature?

In many places we're taking this data from localStorage - by the same time having it in the user.state and cart.state. What we should just make sure of is that these information are properly loaded from localStorage first

Example: https://github.com/DivanteLtd/vue-storefront/blob/2328ec8f8942cbdcc6b371120ba0984553a50ee1/core/client-entry.ts#L241

We should find all the current-token and current-cart-token references and do refactoring to get the info from Vuex getters.

@pkarw pkarw added refactor Code refactoring P2: Important Priority mark - still high ;) labels Feb 27, 2019
@filrak filrak self-assigned this Mar 4, 2019
pkarw added a commit that referenced this issue May 12, 2019
@pkarw pkarw closed this as completed May 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P2: Important Priority mark - still high ;) refactor Code refactoring
Projects
None yet
Development

No branches or pull requests

2 participants