Loki-Code201 / foodwise

With this app one will be able to reduce food waste as well as track food purchases. It will enable a user to monitor their food inventory.
https://loki-code201.github.io/foodwise/
MIT License
1 stars 1 forks source link

Refactor: Abstracted functions #59

Closed KasonBraley closed 3 years ago

KasonBraley commented 3 years ago

Refactors functions in pantry.js to be more reusable. This should help in using this same code for the shopping list table page and any other pages we ever add.

Please read the changes and ask question if it doesn't make sense. I am more than happy to explain any of it. Also please test the code if possible, you can pull down the abstraction branch and run live-server on that branch. This will enable you to test this new code.

I tested myself and it didn't observe any bugs, but I would like to have others test as well. The code itself should produce the exact same results as before, it is just for generic and reusable.