4b11b4 / potify

[S]potify generic music player learning project
0 stars 1 forks source link

Installvuepratice #11

Closed 4b11b4 closed 5 years ago

4b11b4 commented 5 years ago

Check out the README in this branch. The steps for installing Vue should are for my Ubuntu 16.04 system, but you should be able to get by...

One thing to note is that this install does not have any mention of installing nodejs or yarn which are required for going off the tutorial you sent me. Yarn also implies npm. https://johnfraney.ca/posts/2019/05/14/integrate-django-vuejs/

I'm not sure how we would go about tracking those dependencies...

Lastly, I should probably explain that in order for this to work you need both the Vue server and Django server running. The URL for the Django server (http://127.0.0.1:8000/) still takes you to the Django homepage which simply shows an unordered list of the Django Models we defined.

You need both the Django and Vue "server" running in order for Vue to be able to talk to the Django API. Currently, the tutorial that you linked does this in a pseduo-sort of way. Vue doesn't actually hit the API, it just sets up a URL to execute a function which returns JSON.

I explain it in one of the commit messages. It's obvious enough if you look at potify/views.py and potify/urls.py.

4b11b4 commented 5 years ago

see issue #10