django-templatestore
is a Django application/ UI tool to edit and save your templates.
Follow steps to quickly add django-templatestore
to your existing django application:
- Install
django-templatestore
pip install django-templatestore
- Add
templatestore
to yourINSTALLED_APPS
insettings.py
:INSTALLED_APPS = [ ... 'templatestore', ]
- Include the
templatestore
URLconf in your project'surls.py
:path('templatestore/', include('templatestore.urls')),
- Run
python manage.py collectstatic
to collect the static files into root static folder. - Run
python manage.py migrate
to create thetemplatestore
models. - Start the development server and visit
http://127.0.0.1:8000/templatestore/
to start editing templates.
Currently following templating libraries are supported:
-
python
pip install -r requirements.txt # python
node
cd templatestore/frontend/ && npm install && cd - # node packages
-
- Migrate database
python manage.py migrate
- Build js and collect static files
cd templatestore/frontend/ && npm run build && cd - && python manage.py collectstatic --noinput
- Run application
python manage.py runserver
- Migrate database