Venture Theme: Add item count to header cart icon

Hi,

I am using the venture theme and would like to add item count to the header cart icon in my store. I have searched but have not found a solution to this problem. I would like to have the item count update as items are added without having to refresh the page.

1 Like

@premija

Welcome to the Shopify community!
and Thanks for your question.

Please share your site URL,
So I will check and provide a solution here.

1 Like

@KetanKumar

Thank you for your welcome and below is the website URL and password.

Store link - https://premija-llc.myshopify.com/

Password - phiame

1 Like

@premija

do you need a product page or product listing?

@KetanKumar

I have 5 test products listed. When I add items to my cart, it is shown as seen in the photo below.

@premija

It can be done by doing some code customization. please send me a personal message and we can discuss what you’d like

@KetanKumar

I have sent you a personal message as requested.

@premija

Great, Thanks i will check and let you know

Here is the solution. :slightly_smiling_face:

Please find this code in Sections/header.liquid


Replace it with this new code

{{ cart.item_count }}

Add this code to assets/theme.scss.liquid bottom of the file

.site-header__cart-indicator--visible {
  	top: 9px !important;
    width: 15px !important;
    height: 15px !important;
    color: #fff;
    font-size: 15px;
    text-align: center;
}

End results

![Screenshot (657).png|69x56](upload://dI03QbBrbuqxJpIkhe1ULV0VkW9.png)

Screenshot (656).png

I hope this works for anyone else that’s using the Venture theme and is trying to add item count to their cart icon.

2 Likes

@premija

thanks for update

Premija, that worked great. Thank you for that.

1 small thing however;

number of item wont show up in cart unless you refresh screen.

Can coding be adjusted so that when you add an item to cart, it indicates so without refreshing screen?

using Venture