Optional - Set format on save and any global prettier options
npm i -D eslint prettier eslint-plugin-prettier eslint-config-prettier eslint-plugin-node eslint-config-node
import sqlalchemy | |
from sqlalchemy.ext.declarative import declarative_base | |
from sqlalchemy import Column, Integer, String, ForeignKey | |
from sqlalchemy.orm import sessionmaker, relationship | |
engine = sqlalchemy.create_engine('sqlite:///:memory:') | |
Base = declarative_base() | |
# with AJAX withCredentials=false (cookies NOT sent) | |
Header always set Access-Control-Allow-Origin "*" | |
Header always set Access-Control-Allow-Methods "POST, GET, PUT, OPTIONS, PATCH, DELETE" | |
Header always set Access-Control-Allow-Headers "X-Accept-Charset,X-Accept,Content-Type" | |
RewriteEngine On | |
RewriteCond %{REQUEST_METHOD} OPTIONS | |
RewriteRule ^(.*)$ $1 [R=200,L,E=HTTP_ORIGIN:%{HTTP:ORIGIN}]] | |
# with AJAX withCredentials=true (cookies sent, SSL allowed...) | |
SetEnvIfNoCase ORIGIN (.*) ORIGIN=$1 |
# | |
# templatetags/kwacros.py - Support for macros in Django templates | |
# | |
# Based on snippet by | |
# Author: Michal Ludvig <michal@logix.cz> | |
# http://www.logix.cz/michal | |
# | |
# modified for args and kwargs by Skylar Saveland http://skyl.org | |
# |