Inspired by dannyfritz/commit-message-emoji
See also gitmoji.
Commit type | Emoji |
---|---|
Initial commit | 🎉 :tada: |
Version tag | 🔖 :bookmark: |
New feature | ✨ :sparkles: |
Bugfix | 🐛 :bug: |
class StreamingView(TemplateView): | |
""" | |
""" | |
template_name = 'experiments/streaming.html' | |
class StreamingOfferView(CsrfExemptMixin, View): | |
""" | |
""" | |
@classonlymethod |
from django.urls import path | |
from . import views | |
urlpatterns = [ | |
path('offer', views.OfferView.as_view(), name='offer'), | |
] |
""" | |
ASGI config for djinar project. | |
It exposes the ASGI callable as a module-level variable named ``application``. | |
For more information on this file, see | |
https://docs.djangoproject.com/en/dev/howto/deployment/asgi/ | |
""" | |
import os |
import asyncio | |
from django.http.response import HttpResponse | |
from django.utils.decorators import classonlymethod | |
from django.views.generic import View | |
class OfferView(View): | |
"""Base Async View.""" | |
import asyncio | |
from django.utils.decorators import classonlymethod | |
from django.views.generic import View | |
class OfferView(View): | |
"""Base Async View.""" | |
@classonlymethod |
Inspired by dannyfritz/commit-message-emoji
See also gitmoji.
Commit type | Emoji |
---|---|
Initial commit | 🎉 :tada: |
Version tag | 🔖 :bookmark: |
New feature | ✨ :sparkles: |
Bugfix | 🐛 :bug: |
""" | |
Django ORM Optimization Tips | |
Caveats: | |
* Only use optimizations that obfuscate the code if you need to. | |
* Not all of these tips are hard and fast rules. | |
* Use your judgement to determine what improvements are appropriate for your code. | |
""" | |
# --------------------------------------------------------------------------- |
{% load static %} | |
<!DOCTYPE html> | |
<html> | |
<head> | |
<link href="https://fonts.googleapis.com/css?family=Roboto:100,300,400,500,700,900" rel="stylesheet"> | |
<link href="https://cdn.jsdelivr.net/npm/@mdi/font@4.x/css/materialdesignicons.min.css" rel="stylesheet"> | |
<link href="https://cdn.jsdelivr.net/npm/vuetify@2.x/dist/vuetify.min.css" rel="stylesheet"> | |
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no, minimal-ui"> | |
</head> | |
<body> |
from django.views.generic import TemplateView | |
from rest_framework import filters | |
from rest_framework.generics import ( | |
ListAPIView, | |
CreateAPIView, | |
RetrieveUpdateDestroyAPIView | |
) | |
from .models import Contact | |
from .serializers import ContactSerializer, ContactCreateSerializer |