How to display custom pre-order messages in the shopping cart?

In our store we have items that can be “pre-ordered”. When they add the item to the shopping cart, there should be a message under the item warning the user that it is a pre-order item. The products have a tag that is labeled “pre-order”. I have tried the following code in quick-cart.liquid to display the message: `{% for item in cart.items %}

{% if item.product.tags contains 'pre-order' %}

Please Note: your cart contains a pre-order item that may ship separately.

{% endif %} {% endfor %} `

This works to display, however when the item is removed from the cart, the warning still displays till the next page refresh.

I could refresh the page after each item is removed from the cart, which is not ideal. I have been looking at classic.theme.js under the rendering of each cart item. The problem with this idea is that I do not have access to the product tags.

Any ideas or suggestions would be greatly appreciated.

Hi @paul_carlson_r ,

I am assuming that the you don’t have Dawn theme or the free Shopify 2.0 themes. You can actually check the cart.js and call a function to hide and show the message

I am using the spark theme.

Hi @paul_carlson_r ,

Please send your site and if your site is password protected, please send me the password. I will check it.

Hi @paul_carlson_r ,

Please refer the video below to implement the same.

Video instructs how you can add custom msg at cart page based on product.