# Tag Info

5

Prefer modern syntax You're using a few ES2015+ features already, including async/await. If you're going to write a script containing modern syntax (which you should - it can make code much easier to read and write), best to use it everywhere. In particular: Use const (or let when you need to reassign) instead of var. var has too many problems to be worth ...

4

Indentation Much of the indentation in the HTML, CSS, and JS is inconsistent, which makes the code moderately harder to read than would be ideal. Consider using an IDE which automatically formats code properly so things can be made readable without having to mess with it manually. Duplicate IDs are invalid HTML You have two elements with div id="egg&...

1

DRYing The separate numeric-indexed IDs are used only to get to their children .cart-quality-input elements, so you can just select those elements directly instead and remove the IDs. When you have to select something else in the same row, first use: const $row =$(this).closest('.cart-row'); and you'll get to the row, from which you can, with .find, ...

Only top voted, non community-wiki answers of a minimum length are eligible