https://github.com/half0wl/drf-vue-boilerplate
https://github.com/half0wl/drf-vue-boilerplate
Last synced: over 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/half0wl/drf-vue-boilerplate
- Owner: half0wl
- Created: 2017-04-13T20:25:02.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-04-14T00:58:53.000Z (over 9 years ago)
- Last Synced: 2025-02-07T18:49:29.472Z (over 1 year ago)
- Language: Python
- Size: 7.81 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# drf-boilerplate
Minimal boilerplate for REST API development with Django REST framework.
Comes with JWT authentication and an `accounts` module (only requires email and password).
Frontend with django-webpack-loader, Webpack, and Vue.
(Messy, work in progress)
### Installation
```bash
$ virtualenv .venv && source .venv/bin/activate
$ pip install django
$ django-admin startproject \
--template=https://github.com/half0wl/drf-vue-boilerplate/zipball/master \
$ cd
$ pip install -r requirements.txt
$ npm install
```
### Usage
Migrate db: `$ python manage.py makemigrations accounts && python manage.py migrate`
Start Webpack: `$ npm run frontend`
Start Django: `$ npm run backend`
### Endpoints
```
POST api/accounts/register
Params:
- email
- password
Returns:
- User
POST api/accounts/obtain-jwt-token
Params:
- email
- password
Returns:
- JWT token, if credentials are valid
```