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

Product tags undefined #201

Open
AgustReon opened this issue Mar 3, 2021 · 0 comments
Open

Product tags undefined #201

AgustReon opened this issue Mar 3, 2021 · 0 comments

Comments

@AgustReon
Copy link

Hi,

All products in the store I'm working on have tags on them yet they are all undefined in CartJS.cart

quantity: 3
requires_shipping: true
sku: "6878682"
tags: undefined
taxable: true
title: "Origins India"
total_discount: 0

I can see the tags when I use normal liquid syntax.

{% for item in cart.items %}
  {{item.product.handle}}
  {% for tag in item.product.tags %}
    {{tag}}
  {% endfor %}
{% endfor %}

Is this a bug or is there something required in init to access tags?

If not is there a way to get the handle from CartJS and access {{ all_products[CartJS.cart.items[index].product.handle].tags }}?

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

No branches or pull requests

1 participant