Installation¶
Only with Python/django¶
Install with:
1 | pip3 install django-partitialajax
|
Than put partitialajax into your INSTALLED_APPS:
1 2 3 4 | INSTALLED_APPS = [
...
partitialajax
]
|
Add the JS libary to each page you have Partitials:
1 2 3 4 | ...
{% static 'partitialajax/index.js' %}
</head>
...
|
JS / Python Setup¶
You can also use the js src to build your own javascript set for every page
Install with
1 2 | pip3 install django-partitialajax
npm install django-partitialajax --save
|
Tipp: If you use webpack for your js code use the django-webpack-loader libary.
To use the “autodiscover” for elements with partitial loading use the following JS code: