a restful website visualizing Taiwan FDA food nutrition fact of items you select
- Frontend:
- React: app architecture
- Redux: state container
- Redux-Thunk
- Redux-Saga
- d3, recharts: visualize the data
- Backend:
- Django, Django REST framework: backend api
- Python: crawler
- select(pin) the items and see their nutrition facts
- fill the target-form(calories, fat, protein and carbs) and get the comparison between target and select items
We use redux-thunk and redux-saga to implement redux async actions. To avoiding over-frequently request to server, we use redux-saga to set timeout when you type the search keyword.
-
Install postgresql
-
[Optional] Create virtual envirnment
-
virtualenv --no-site-package venv
-
Install dependency
pip install -r requirements.txt
-
Create user nutrika
createuser -Psrle nutrika
If you get the error
psql: could not connect to server
, read the this post -
Create db nutrika
createdb nutrika
-
Insert Data into Database
python manage.py import_nutrition
-
Run server
python manage.py runserver
- form to add items
- algorithm to filter unreliable information
- add items by photo(maybe...)