Items.reduce((acc, item) => acc + item.price, 0) / 100).toFixed(2)}</p>
          <ul>
            ${this.cartItems.map(item => html`
              <li>${item.name} - ${(item.price / 100).toFixed(2)} <button @click=${() => CartStore.dispatch('remove', item)}>Remove</button></li>
            `)}
          </ul>
        ` : html`
          <p>Cart is empty</p>
        `}
      `
    }
  }

  customElements.define('cart-component', CartElement);
</script>

</body>
</html>
