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

Topic summary

A user is trying to display a warning message in the shopping cart when a product tagged as “pre-order” is added. They implemented code in quick-cart.liquid that successfully shows the message, but it persists after the item is removed until the page is manually refreshed.

Current Issue:

  • The warning message doesn’t disappear dynamically when pre-order items are removed from cart
  • Page refresh is required to clear the message, which creates poor user experience

Attempted Solutions:

  • Considered modifying classic.theme.js to handle cart item rendering, but product tags aren’t accessible there
  • Looking for a way to update the message dynamically without forcing page refreshes

Community Responses:

  • One suggestion involves using cart.js to create a function that shows/hides the message dynamically
  • Another user requested site access and password to investigate directly
  • A YouTube tutorial was shared demonstrating how to add custom messages at cart page based on product properties

Theme Context: The store uses the Spark theme (not Dawn or Shopify 2.0 themes).

The discussion remains open with no confirmed solution implemented yet.

Summarized with AI on October 28. AI used: claude-sonnet-4-5-20250929.

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.