Skip to main content

django-dynamic-breadcrumbs

Django CI Coverage Status PyPI version Code style: black Downloads Documentation Status

django-dynamic-breadcrumbs is a Django app to generate HTML breadcrumbs dynamically from URL paths.

At https://example.com/reference/instrument/guitar/, shows: Home > Reference > Instrument > Guitar.

Quick start

1. Install

pip install django-dynamic-breadcrumbs

2. Add to settings

Add "dynamic_breadcrumbs" label to your INSTALLED_APPS settings:

INSTALLED_APPS = [
    ...
    'dynamic_breadcrumbs',
]

Add dynamic_breadcrumbs.context_processors.breadcrumbs to context_processors:

TEMPLATES = [
    {
        "BACKEND": "django.template.backends.django.DjangoTemplates",
        "DIRS": [os.path.join(BASE_DIR, "templates")],
        "APP_DIRS": True,
        "OPTIONS": {
            "context_processors": [
				#...
                "dynamic_breadcrumbs.context_processors.breadcrumbs",
            ],
        },
    },
]

3. Add template

Include the dynamic_breadcrumbs/breadcrumbs.html in your base template.

{% if breadcrumbs %}
<div class="container">
    {% include "dynamic_breadcrumbs/breadcrumbs.html" with breadcrumbs=breadcrumbs%}
</div>
{% endif %}

Now each time you visit a page which makes use of the above template, it will have the breadcrumbs generated from the URL path.

4. (Optional) Customization

Tweak default settings.

Documentation

Full docs at: https://django-dynamic-breadcrumbs.readthedocs.io/

License

MIT

Metadata

Release files for django-dynamic-breadcrumbs 0.4.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-dynamic-breadcrumbs 0.4.3
File Size Uploaded Provenance
django-dynamic-breadcrumbs-0.4.3.tar.gz 10.2 kB Without provenance Details

Release files / django-dynamic-breadcrumbs-0.4.3.tar.gz

Download URL django-dynamic-breadcrumbs-0.4.3.tar.gz
Size 10.2 kB
Tags Source
SHA-256 checksum
How to use checksums
a6e89a67eabd47aa32fea3f55a3f5fb89bfccc90a35d0119e2b30656914eaa4b
BLAKE2b-256 checksum
How to use checksums
637e417a8f176f1fbf03a9a10320d976e8352de54153c0efed3bc06339babcef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.8.10

Security for django-dynamic-breadcrumbs 0.4.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page