demand:
vuex.state
idea:
my initial idea is to get the list of shopping carts in state when I first enter the page, and when I cycle the product, send product information to the computing attribute to determine whether it has been purchased in the shopping cart. When you click Buy, you can dynamically change the value of the calculated property by changing only the number of shopping carts.
I would like to ask you, is there a better solution? I have learned to use component implementation to pass product information to the component when looping, and to use computational properties within the component. But is there any good way if you don"t use components?