Reorganize api files
This commit is contained in:
parent
a5e9ee1357
commit
07e27b8d1e
10
README.md
10
README.md
|
@ -125,6 +125,16 @@ within each relevant app, sometimes it makes more sense to build an app
|
||||||
specifically for the API. This is where all the serializers, renderers, and views
|
specifically for the API. This is where all the serializers, renderers, and views
|
||||||
are placed. Therefore, the name of the app should reflect its API version
|
are placed. Therefore, the name of the app should reflect its API version
|
||||||
|
|
||||||
|
##### `api-versioning`
|
||||||
|
It might often be necessary to support multiple versions of an API throughout the lifetime of a project. Therefore, we're adding in support right from the start.
|
||||||
|
|
||||||
|
For different API versions, we're assuming the following will change:
|
||||||
|
- Serializers
|
||||||
|
- Views
|
||||||
|
- URLs
|
||||||
|
- Services
|
||||||
|
|
||||||
|
Whereas the `model`s will be shared.
|
||||||
|
|
||||||
### `config`
|
### `config`
|
||||||
* Contains project configuration files, including the primary URL file
|
* Contains project configuration files, including the primary URL file
|
||||||
|
|
|
@ -1,3 +0,0 @@
|
||||||
from django.contrib import admin
|
|
||||||
|
|
||||||
# Register your models here.
|
|
|
@ -1,3 +0,0 @@
|
||||||
from django.test import TestCase
|
|
||||||
|
|
||||||
# Create your tests here.
|
|
|
@ -1,2 +0,0 @@
|
||||||
APIView
|
|
||||||
def does one thing
|
|
|
@ -1,6 +0,0 @@
|
||||||
from django.apps import AppConfig
|
|
||||||
|
|
||||||
|
|
||||||
class AppConfig(AppConfig):
|
|
||||||
default_auto_field = 'django.db.models.BigAutoField'
|
|
||||||
name = 'app'
|
|
|
@ -1,3 +0,0 @@
|
||||||
from django.db import models
|
|
||||||
|
|
||||||
# Create your models here.
|
|
Loading…
Reference in New Issue