javascript

JS incrementing quantity 2 by 2 instead of 1 by 1  #angularjs #reactjs

  • Stack Overflow works best with JavaScript enabled
  • Join the Stack Overflow Community
  • Browse other questions tagged javascript shopify or ask your own question .
  • Stack Overflow is a community of 6.6 million programmers, just like you, helping each other.
  • sign up log in tour help

I’m creating a shopify theme but when i add this script to carti got a bug. Whe you try increment products in cart they jump 2 by 2.

@ng_real_ninja: JS incrementing quantity 2 by 2 instead of 1 by 1 #angularjs #reactjs

I’m creating a shopify theme but when i add this script to carti got a bug. Whe you try increment products in cart they jump 2 by 2.

I dont think you actually need the JS for this input type to work, so adding or removing values inside of the JS is like just double-adding or double-removing values 😉

Hope this can help !

if ((“.quantity”).length > 0) { var form_cart = $(“form .quantity”); form_cart.prepend(”); form_cart.append(”);

javascript

You might also like More from author

Comments are closed, but trackbacks and pingbacks are open.