ahlev-django-css-js

static files


License
BSD-3-Clause
Install
pip install ahlev-django-css-js==0.0.2

Documentation

DJANGO CSS JS APPLICATION

pypi status

This django application is used to add the styles from mdbootstrap.com into both frontend and backend of any ahlev django project.

prerequisites

The instructions below assume that you have a django project already set up; and a python virtual environment already installed and activated.

install from this repository

clone

git clone https://github.com/ohahlev/ahlev-django-css-js.git

go to directory ahlev-django-css-js

cd ahlev-django-css-js

create installer package

make package

install package

Let's say ahlev-django-css-js directory is in the same level as the project directory.

cd into project directory

cd ../my_project_dir

install ahlev-django-css-js from the project directory

pip install ../ahlev-django-css-js/dist/ahlev-django-css-js-0.0.1.tar.gz

install from pypi

ahlev-django-css-js

project configuration

update settings.py as the following

INSTALLED_APPS = [
    'css_js', # add this line
    ...
]

add these lines to the end of settings.py

STATICFILES_DIRS = [
    os.path.join(BASE_DIR, "static")
]
STATIC_URL = '/static/'
MEDIA_ROOT = os.path.join(BASE_DIR, 'uploads')
MEDIA_URL = '/medias/'