Skip to content

fablefebvre/food-compare

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 

Repository files navigation

food-compare

Food comparison with Open Food Facts Data

Load Open Food Facts Mongo DB Dump:

Download the dump

https://world.openfoodfacts.org/data/openfoodfacts-mongodbdump.tar.gz

Launch restore:

On MacOS need to increase number of opened files (256 be default for a process) with the command: ulimit -S -n 2048

mongorestore --port

Create index for categories

off.products.createIndex({categories_tags: 1})

food-compare-be

Contains the back end: REST API with mongoose to connect to the MongoDB instance Run the sever: node server.js Available methods in the API: http://localhost:4000/api/categories => Returns distinct categories in DB http://localhost:4000/api/categoriesTax => returns all FR categories of https://en.wiki.openfoodfacts.org/Global_categories_taxonomy http://localhost:4000/api/findBestProducts/:category => returns the best products for the given category

food-compare-fe

Contains the front end: Developed with Vue.js Run the sever: npm run serve Launch the app: http://localhost:8081/

About

Food comparison with Open Food Facts Data

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors