HTML content blocks for Django.
Project description
Django Content Blocks
Django Content Blocks is a reusable Django app that allows users to create and manage custom content blocks for their website. Via the django admin site it provides an easy-to-use interface for creating content blocks that can be related to any other object. This allows you to provide rich, dynamic, editable content for your existing models such as pages, products, projects or whatever your project has.
The templates used to render content blocks are made in the same way as any other template in your project, giving you access to the full power of your chosen template engine.
Content blocks can contain any type of content, including text, images, videos, and more, and can be arranged in any order. Additionally, Django Content Blocks includes support for drafts and previews, allowing users to see how their changes will look before publishing them.
Installation instructions and detailed documentation can be found on ReadTheDocs.
Development Status & Roadmap
Django content blocks is already in use in a number of production websites however it is still considered to be in beta as active development continues.
Major development plans/ideas include:
- Rework the cacheing system to make it a lot simpler
Currently content blocks are pre cached on publish. This becomes complex when sites are considered. The intention is to remove pre-cacheing and only cache on render, greatly simplifying the cacheing system.
- Content block editor HTML, CSS and JS rework.
This all needs updating to use modern HTML and CSS (flex, grid etc) and vanilla JS.
Currently using jQuery which isn’t the end of the world as it comes with django.contrib.admin so not an extra dependency.
- Option for vertical layout for nested forms in the content block editor
Sometimes nested blocks can represent columns within a content block. It would be nice to give the option to have these shown side by side in the content block editor.
- django-content-blocks 2.0
This will be a major rewrite which will move the representation of content blocks out of the database and into a JSONField. This will greatly improve performance as the whole representation of an object’s content blocks can be returned at once and any subsequent queries required can be made in a prefetch fashion.
The ContentBlockField will become pluggable allowing developers to add/remove available fields from within their project.
- Django content blocks suite of apps providing additional functionality and basic apps powered by content blocks:
CMS
Blog
Contact forms
Dependencies (and Thank You)
Thank You
https://shystudios.co.uk - For the monies I need to eat
https://opalstack.com/?lmref=A2GlhA - For great value hosting and superb support over the years (affiliate link)
https://chat.openai.com/ - For documentation rewrites
https://github.com/django-hijack/django-hijack - For conf.py LazySettings idea
https://github.com/cookiecutter/cookiecutter-django - For many things including docker
Dmitry Sobolev for so graciously transferring the django-content-blocks name on pypi
Margo Yaguda for linguistic assistance in contacting Dmitry
Contributing
Contributions, advice and guidance are welcome. Please make contact before writing any code!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for django-content-blocks-1.3.5.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | dcab1f3b8885a6f909c1981c790bf4569c3a61ac647651819a32ceefea222044 |
|
MD5 | 7934690a84dd2fc94bf103b8db327caf |
|
BLAKE2b-256 | 2d45a5e928150d939cae38d349edf5ea95cfbc3c2544f53338f16d0d9acf08d2 |
Hashes for django_content_blocks-1.3.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b238967564e07e658e11a2fde67268cdbbfe924d1611424758d0cbea012c205b |
|
MD5 | 903d57e7b0e3b657459b995f7fd5129c |
|
BLAKE2b-256 | e8f4e876e015a06337dd5bbed22f0be5202e76e1205368a10cbaf9478d69fded |