Django Tabler

screenshot of Django Tabler
django

Django package for the Tabler dashboard

Overview:

The django-tabler project is a Django package that transforms the Tabler dashboard into a Django template. It provides a base template, error page templates, and necessary static assets. It is based on the latest Tabler release v0.0.32.

Features:

  • Extensible base template
  • Error page templates
  • Provides necessary static assets

Usage:

Once installed, you can extend django-tabler's base template in your application's templates. For example:

{% extends "django_tabler/base.html" %}

For more templates and inspiration, you can refer to the templates provided by the original Tabler project.

Using Django's Sites framework, django-tabler's base template also adds your site's name to the browser's title bar. To set this up, follow these steps:

  1. Add a SITE_ID value to your application's settings file.
  2. Add 'django.contrib.sites' to your INSTALLED_APPS.
  3. Add 'django.contrib.sites.middleware.CurrentSiteMiddleware' to your MIDDLEWARE.
  4. Run python manage.py migrate if necessary.
  5. Update the record in your application's django_site database table that corresponds to the SITE_ID value with an appropriate name and domain. You can use a custom migration for this.

To load a favicon, create an img/ folder inside your application's static directory and place the favicon.ico file inside it. The icon will be loaded by the base template.

Django-tabler also overrides Django's default error views by rendering a custom error template. To access these views, add the following to your application's urls.py file:

from django_tabler import views as tabler_views

handler400 = tabler_views.error_400
handler403 = tabler_views.error_403
handler404 = tabler_views.error_404
handler500 = tabler_views.error_500

Summary:

Django-tabler is a package that integrates the Tabler dashboard into Django projects. It provides a base template, error page templates, and necessary static assets. It can be easily installed and used to enhance the UI of Django applications.

django
Django

Django is a high-level Python web framework that encourages rapid development and clean, pragmatic design. It follows the model-view-controller (MVC) architectural pattern, providing an extensive set of built-in tools and conventions to streamline the creation of robust and scalable web applications.

dashboard
Dashboard

A dashboard style website template is a pre-designed layout that features a user interface resembling a control panel or dashboard. It typically includes charts, graphs, tables, and other data visualization tools that allow users to monitor and analyze data in real-time.