Skip to content

Instantly share code, notes, and snippets.

View 8area8's full-sized avatar
🦧
Focusing

Mikael Briolet 8area8

🦧
Focusing
View GitHub Profile
@8area8
8area8 / README.md
Last active February 17, 2022 23:42
VueCLI + FastAPI

VueCLI + FastAPI

This Gist allows to run VueCLI in FastAPI.

  • In dev, you will have to launch both servers and use fastAPI for navigation.
  • In prod, it will be enough to build VueCLI, and you will have to launch FastAPI only.

Base Skeleton

@8area8
8area8 / README.md
Last active September 21, 2021 15:40
Django/Vue-cli coupling

Basic workflow to Django/Vue-cli coupling

The goal of this workflow is to couple vue-cli to Django, in a transparent way in dev and in prod. The hot-reload is active in the backend as well as in the frontend, and the frontend is accessed through Django, from the index page ;)

Note: We also use the router's historical mode, for a more professional integration.

Note²: Do not forget to build the vue-cli project for production!

Base

@8area8
8area8 / forms.py
Created August 5, 2021 09:08
Django - User form for admin panel (not safe)
"""User forms."""
from django import forms
from django.contrib.auth import get_user_model
from django.contrib.auth.forms import UserCreationForm
from django.utils.translation import gettext_lazy as _
User = get_user_model()
@8area8
8area8 / $README.md
Last active September 6, 2020 12:05
Django & Vue-cli coupling ~ useful for Heroku ~

Django & Vue-cli coupling ~ useful for Heroku ~

python badge django badge vue-cli badge

Allows to couple Django and Vue-cli easily, without any plugin or additional library.

Note : Hot Reload is active with this configuration.

@8area8
8area8 / README.md
Last active September 6, 2020 11:17
Vscode personal settings.

VSCode settings

useful for:

  • windows

with the following languages :

  • python
  • javascript
@8area8
8area8 / README.md
Last active September 5, 2020 12:49
Django apps management

Django apps structure.

Use this to manage yours apps inside your backend directory:

.
|____django_dir
| |____apps
| | |____your_app_folder
| |__settings.py
|____manage.py