This release is a pre-release and may not be stable for production use.
A Django backend for the Toga widget toolkit.
This package isn’t much use by itself; it needs to be combined with the core Toga library and the Toga Web library.
For more details, see the Toga project on Github.
Prerequisites
This backend requires Django 3.0 as a minimum requirement.
Usage
Toga Django defines a TogaApp class that can be used to mount a Toga Web instance in a Django app. If you have Toga application named myapp, Django deployment is acheived by putting the following into your project’s urls.py:
from django.conf import settings
from django.conf.urls.static import static
from django.contrib import admin
from django.urls import path
from toga_django import TogaApp
from tutorial import app
urlpatterns = [
path('admin/', admin.site.urls),
path('/', TogaApp(app).urls),
] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
This will mount the Toga app at /, the Django admin at /admin, and serve static content in debug mode. You can mount the app at any URL you wish, and you can also add other routes for other views.
The app can then be executed with:
$ ./manage.py runserver
This assumes a standard Toga app layout, where the application myapp has a submodule app.py that defines a main() method.
Community
Toga is part of the BeeWare suite. You can talk to the community through:
Contributing
If you experience problems with this backend, log them on GitHub. If you want to contribute code, please fork the code and submit a pull request.
Metadata
Release files for toga-django 0.3.0.dev35
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| toga-django-0.3.0.dev35.tar.gz | 4.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| toga_django-0.3.0.dev35-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.3 kB
Release files / toga-django-0.3.0.dev35.tar.gz
| Download URL | toga-django-0.3.0.dev35.tar.gz |
|---|---|
| Size | 4.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d0de87e7239e10689b9df9e80a6956e7b087cdc7efe33c1bc161d5705a09c029
|
|
BLAKE2b-256 checksum How to use checksums |
3ccd538326db8ee455df6874d966e1a7af221c9edfd0b644630cb6240dcbadc1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.10.3
|
Release files / toga_django-0.3.0.dev35-py3-none-any.whl
| Download URL | toga_django-0.3.0.dev35-py3-none-any.whl |
|---|---|
| Size | 4.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f39a255b3e2a11c11ded697e2857070c6d783780b7aa115adf97f90827d91fc8
|
|
BLAKE2b-256 checksum How to use checksums |
93247c6647c81c93bbcc9f34f6021c76d649e17aa838813c2a3044b7cfaa05f5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.0 CPython/3.10.3
|