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.
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.